<commit_before>/*
 * Copyright (C) 2019 - present Instructure, Inc.
 *
 * This file is part of Canvas.
 *
 * Canvas is free software: you can redistribute it and/or modify it under
 * the terms of the GNU Affero General Public License as published by the Free
 * Software Foundation, version 3 of the License.
 *
 * Canvas is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Affero General Public License along
 * with this program. If not, see <http://www.gnu.org/licenses/>.
 */
import gql from 'graphql-tag'

import {Assignment, AssignmentSubmissionsConnection} from './Assignment'
import {ExternalTool} from './ExternalTool'
import {ProficiencyRating} from './ProficiencyRating'
import {Rubric} from './Rubric'
import {RubricAssessment} from './RubricAssessment'
import {SubmissionComment} from './SubmissionComment'
import {SubmissionHistory} from './SubmissionHistory'
import {UserGroups} from './UserGroups'

export const EXTERNAL_TOOLS_QUERY = gql`
  query ExternalTools($courseID: ID!) {
    course(id: $courseID) {
      externalToolsConnection(filter: {placement: homework_submission, state: public}) {
        nodes {
          ...ExternalTool
        }
      }
    }
  }
  ${ExternalTool.fragment}
`

export const RUBRIC_QUERY = gql`
  query GetRubric($rubricID: ID!, $submissionID: ID!, $courseID: ID!, $submissionAttempt: Int!) {
    rubric: node(id: $rubricID) {
      ... on Rubric {
        ...Rubric
      }
    }
    submission(id: $submissionID) {
      rubricAssessmentsConnection(filter: {forAttempt: $submissionAttempt}) {
        nodes {<commit_msg>return google drive lti tool in tools query<commit_after>/*
 * Copyright (C) 2019 - present Instructure, Inc.
 *
 * This file is part of Canvas.
 *
 * Canvas is free software: you can redistribute it and/or modify it under
 * the terms of the GNU Affero General Public License as published by the Free
 * Software Foundation, version 3 of the License.
 *
 * Canvas is distributed in the hope that it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
 * A PARTICULAR PURPOSE. See the GNU Affero General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Affero General Public License along
 * with this program. If not, see <http://www.gnu.org/licenses/>.
 */
import gql from 'graphql-tag'

import {Assignment, AssignmentSubmissionsConnection} from './Assignment'
import {ExternalTool} from './ExternalTool'
import {ProficiencyRating} from './ProficiencyRating'
import {Rubric} from './Rubric'
import {RubricAssessment} from './RubricAssessment'
import {SubmissionComment} from './SubmissionComment'
import {SubmissionHistory} from './SubmissionHistory'
import {UserGroups} from './UserGroups'

export const EXTERNAL_TOOLS_QUERY = gql`
  query ExternalTools($courseID: ID!) {
    course(id: $courseID) {
      externalToolsConnection(filter: {placement: homework_submission}) {
        nodes {
          ...ExternalTool
        }
      }
    }
  }
  ${ExternalTool.fragment}
`

export const RUBRIC_QUERY = gql`
  query GetRubric($rubricID: ID!, $submissionID: ID!, $courseID: ID!, $submissionAttempt: Int!) {
    rubric: node(id: $rubricID) {
      ... on Rubric {
        ...Rubric
      }
    }
    submission(id: $submissionID) {
      rubricAssessmentsConnection(filter: {forAttempt: $submissionAttempt}) {
        nodes {
{'fraction_non_alphanumeric': 0.10085422981537613, 'fraction_numerical': 0.002755580049600441, 'mean_word_length': 3.7020725388601035, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5995404', 'n_tokens_mistral': 1063, 'n_tokens_neox': 1016, 'n_words': 373}