AlmondTill/G3N API

trainingTutor

query · in the family Your own session

What it does

Ask the tutor a question about one course — it answers from the course’s own steps and the bank’s explanations, naming what it rests on.

Ask the tutor ONE question about ONE course

Before you call

A signed-in user’s session — the call refuses an API key (AUTHZ/FORBIDDEN).

Capability area: Your own session — What every signed-in person may do for themselves — their session, their profile and their own work.

Roles that may call it:

What happens

A tutoring assist that spends kernels; nothing is stored; at most thirty asks an hour.

Arguments

NameTypeRequiredNotes
courseKeyString String!yes
questionString String!yes
stepNIntno

Returns

TrainingTutorAnswer TrainingTutorAnswer! — The tutor's answer: plain words (at most 1200 characters), the grounds it rests on, the model that spoke. Nothing is stored.

Example request

graphql
query ExampleTrainingTutor($courseKey: String!, $question: String!, $stepN: Int) {
  trainingTutor(courseKey: $courseKey, question: $question, stepN: $stepN) {
    answer
    model
  }
}

Variables:

json
{
  "courseKey": "<course key>",
  "question": "<question>",
  "stepN": 1
}

Example response

json
{
  "data": {
    "trainingTutor": {
      "answer": "<answer>",
      "model": "<model>"
    }
  },
  "extensions": {
    "at": {
      "callId": "01EXAMPLE-CALL-ID",
      "version": {
        "requested": null,
        "serviced": {
          "name": "genesis",
          "number": 0
        }
      }
    }
  }
}

Errors this call can answer