Related queries and mutations in Agent traces and evaluations. Each has its own section.
Queries
getReinforcementLoopV2Issues (query)
getReinforcementLoopV2Issues is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Issues the reinforcement loop diagnosed for one agent, each with the conversations it was found in: one node per issue with its current title, description and recommendation, its computed priority and rank, and one entry per conversation carrying the cited turns and the rendering of how the issue shows up there. Sorted by orderBy, rank, then priority, then conversationCount by default; forward-paginated.
Arguments
| Argument | Type | Description |
|---|---|---|
agentName | String | Observability agent name. Required unless issueUuid is given, in which case it is read from the issue. |
traceTableMcon | String | MCON of the agent's trace table — same value passed as traceTableMcon on getAgentGraph. Disambiguates agents with identical names across trace tables. Required unless issueUuid is given, in which case it is read from the issue. |
workflowName | String | Narrow to issues diagnosed in this workflow; their conversations and conversationCount narrow with it. Omit to span every workflow. An empty string is a distinct, explicitly empty-named workflow. To narrow to conversations with no workflow, pass workflowScope: NO_WORKFLOW — that scope has no name to give here. |
workflowScope | ReinforcementLoopWorkflowScope | Which workflow scope to read. Omit for the default: a workflowName narrows to that workflow, its absence spans every workflow. NO_WORKFLOW narrows to conversations whose workflow is null and must be sent without a workflowName; NAMED requires one. |
priorities | [AgentHealthPriority!] | Keep issues whose served priority is one of these. Omit or pass an empty list to span every priority. HIDDEN requires includeHidden. |
includeHidden | Boolean | Also return issues served priority HIDDEN. False by default: hidden issues are left out of the nodes, the counts and emptyReason. Default: false. |
topRankedOnly | Boolean | True keeps each Issue space's top 10, the issues with a rank. False or null keeps every issue. Default: false. |
issueUuid | UUID | Narrow to one issue by its issueUuid. ANDs with the other filters — a mismatch returns empty, not an error. |
issueSpaceUuid | UUID | Narrow to one of the agent's Issue spaces, by the issueSpaceUuid its issues carry. ANDs with the other filters. A space that is not this agent's matches no issue. Ranks are per Issue space, so narrowing does not change them. |
startTime | DateTime | Keep issues with lastSeenAt at or after this instant. Omit for no lower bound. Filters issues by report time. conversations and conversationCount are not restricted to the window; conversationCountInWindow, conversationCountSeries, impactScore and rank are, by conversation time; impactScore and rank read at most its last 90 days. priority is not. |
endTime | DateTime | Keep issues with lastSeenAt at or before this instant. Omit for no upper bound. Must not precede startTime. |
disposition | ReinforcementLoopIssueDisposition | Keep issues with this disposition: NONE for open issues, IGNORED for ignored ones. Omit to span both. |
status | [ReinforcementLoopIssueStatus!] | Keep issues with one of these statuses. Omit, null or empty for all. |
mode | ReinforcementLoopRunMode | LIVE issues by default; BACKTEST reads what backtest runs reported. |
orderBy | [ReinforcementLoopV2IssueOrder!] | Sort keys, applied in order. [RANK, PRIORITY, CONVERSATION_COUNT] by default or when null. Ties left after the listed keys fall to lastSeenAt, newest first. A key may appear once. |
first | Int | Page size, 1..500. Default: 100. |
after | String | Opaque forward-pagination cursor — the previous page's endCursor. Omit for the first page. |
conversationsFirst | Int | Conversations served per issue, newest first, 1..100. conversationCount reports the total. Default: 1. |
conversationSeries | ReinforcementLoopV2ConversationSeriesInput | Adds conversationCountSeries to each issue, over [startTime, endTime). Requires both, with at most 366 buckets. Does not change which issues are listed or their order. |
Returns
ReinforcementLoopV2IssueConnection!
Example
query GetReinforcementLoopV2Issues {
getReinforcementLoopV2Issues {
emptyReason
viewerIsStaff
}
}Types used only by getReinforcementLoopV2Issues
getReinforcementLoopV2IssuesReinforcementLoopConfigAccess
ReinforcementLoopConfigAccessEnum type. What an RL V2 issue's text was written from. FULL read the agent's configuration as well as its traces. TRACES_ONLY read the traces alone, so the issue states the failure with no cause or fix.
| Value | Description |
|---|---|
FULL | |
TRACES_ONLY |
ReinforcementLoopConversationImpact
ReinforcementLoopConversationImpactObject type. How bad one conversation was, as the issue's newest report of it scores it.
| Field | Type | Description |
|---|---|---|
score | Float! | 0 to 1: one minus the product of (1 - entry) over the counted entries. The issue's impactScore adds up the scores of its conversations in the window. |
inWindow | Boolean! | Whether its score counts toward the issue's impactScore: it happened in [startTime, endTime), at most its last 90 days, or in the last 14 days without either bound, within the list's workflow filter. |
entries | [ReinforcementLoopImpactEntry!]! | CORRECTNESS first, then each cluster the report says the issue explains. The cluster entries are empty when cluster content access is denied. |
ReinforcementLoopDraftPrRef
ReinforcementLoopDraftPrRefObject type. The newest draft-PR workflow dispatch for an issue, list-grade.
Enough to render an icon state (pending / opened / failed) and a
click-through; the issue's full dispatch history stays on
getGithubActionTriggerDispatches.
| Field | Type | Description |
|---|---|---|
status | GithubActionTriggerDispatchStatus! | Dispatch lifecycle: DISPATCHED/RUNNING = pending, SUCCEEDED = draft PR opened, FAILED/EXPIRED = no PR produced. |
prUrl | String | Web URL of the draft PR — set once the workflow reports it (SUCCEEDED). |
prNumber | Int | PR number, set together with prUrl. |
prState | GithubActionTriggerDispatchPrState | The PR's state, from the GitHub webhook or the dispatch poller. Null until the poller links the PR. The draft PR counts as work while the dispatch is DISPATCHED or RUNNING, or while this is OPEN. |
ghRunUrl | String | GitHub Actions run URL — the click-through while the workflow is running. |
dispatchedAt | DateTime! | When the workflow dispatch was triggered. |
completedTime | DateTime | When the dispatch reached a terminal status; null while pending. |
ReinforcementLoopImpactEntry
ReinforcementLoopImpactEntryObject type. One signal of how bad a conversation was: its value times its weight.
| Field | Type | Description |
|---|---|---|
kind | ReinforcementLoopImpactEntryKind! | |
clusterKey | String | The cluster the issue explains in this conversation. Null for CORRECTNESS. |
value | Float! | How strongly the conversation shows the signal, 0 to 1. CORRECTNESS: wrong_answer 1, unsupported_answer 0.8, partial_answer 0.5, no_answer 0.5, out_of_reach 0. |
weight | Float! | How much the signal counts: 1, 0.5 or 0.2, fixed by Monte Carlo. 0 for a cluster the loop no longer diagnoses. |
entry | Float! | weight times value. |
counted | Boolean! | False for every COST entry of the conversation but its highest. The cost clusters measure the same lost time, so only the highest counts, and the first of equal entries. |
ReinforcementLoopImpactEntryKind
ReinforcementLoopImpactEntryKindEnum type. What an entry of a conversation's impact measures. CORRECTNESS: how the answer failed the user. YES_NO: a cluster the conversation is in. EVAL: an eval monitor the conversation failed. COST: time or tokens the issue cost.
| Value | Description |
|---|---|
CORRECTNESS | |
YES_NO | |
EVAL | |
COST |
ReinforcementLoopIssueDisposition
ReinforcementLoopIssueDispositionEnum type. What a user decided about an issue. IGNORED issues are left out of the digest.
| Value | Description |
|---|---|
NONE | |
IGNORED |
ReinforcementLoopIssueFeedback
ReinforcementLoopIssueFeedbackObject type. The current feedback on an RL V2 issue. Customers don't see Monte Carlo staff feedback.
| Field | Type | Description |
|---|---|---|
entries | [ReinforcementLoopIssueFeedbackEntry!]! | Each person's current feedback, newest first. Conversation-level entries carry conversationId. Monte Carlo staff feedback is left out for customers. |
upCount | Int! | UP ratings among the issue-level entries. Conversation-level entries aren't counted. |
downCount | Int! | DOWN ratings among the issue-level entries. Conversation-level entries aren't counted. |
history | [ReinforcementLoopIssueFeedbackEntry!]! | Every feedback row on the issue, newest first, including UNDO rows and ratings a newer one replaced. Same staff visibility as entries. Read only when selected. |
ReinforcementLoopIssueFeedbackEntry
ReinforcementLoopIssueFeedbackEntryObject type. One feedback row on an RL V2 issue, or on one of its conversations.
| Field | Type | Description |
|---|---|---|
feedbackUuid | UUID! | |
issueReportUuid | UUID! | The report the person rated. Compare with the node's issueReportUuid to tell whether the issue changed since. |
user | UserBasicInfo | The person who left the feedback. Null once that user is deleted. |
userEmail | String | Display label for the person who left the feedback. Returns the user's email for human users; for agent users, returns a derived display label (e.g. Bayes on <domain>) — never the agent's internal address. Null once that user is deleted. Deprecated: Read user.email.. |
isMine | Boolean! | Left by the caller. |
isStaff | Boolean! | Left by Monte Carlo staff. Only staff see these entries. |
rating | ReinforcementLoopFeedbackRating! | |
reason | ReinforcementLoopFeedbackReason | |
comment | String! | |
conversationId | String | The conversation the feedback is about; null for feedback on the issue. |
shownPriority | AgentHealthPriority | The priority the person saw. |
duplicateOfIssueUuid | UUID | The issue this one duplicates, for reason DUPLICATE. |
suggestedPriority | AgentHealthPriority | The priority the person suggests, for WRONG_PRIORITY. |
priorityReason | ReinforcementLoopFeedbackPriorityReason | |
fixPrUrl | String | The pull request that fixed it, for FIX_WORKED. |
createdTime | DateTime! |
ReinforcementLoopIssueFix
ReinforcementLoopIssueFixObject type. One change that fixed an RL V2 issue.
| Field | Type | Description |
|---|---|---|
changeId | String! | An opaque key. Show ref and changedAt instead. |
kind | String! | pull_request, cortex_agent_spec or cortex_object. New kinds may be added. |
ref | String! | A pull request's URL, or the agent's or object's name. |
changedAt | DateTime | When the change went live. Null when its history could not date it. |
match | String! | How the change compares with the recommendation: same, partial or different. |
reason | String | The changed lines that remove a cause. Null when agent content access is denied. |
missing | String | What the recommendation asked for that the change left out. Null when nothing was, or when agent content access is denied. |
ReinforcementLoopIssueFixSource
ReinforcementLoopIssueFixSourceEnum type. The system behind an RL V2 issue's fix or work. MANUAL = a user marked it fixed or in progress. RL_PR = its draft PR. LINEAR, JIRA and SERVICENOW = its ticket in that system. A fix is recorded when the PR merges or the ticket is done.
| Value | Description |
|---|---|
MANUAL | |
RL_PR | |
LINEAR | |
JIRA | |
SERVICENOW |
ReinforcementLoopIssueOutcome
ReinforcementLoopIssueOutcomeObject type. What an RL outcomes run found about whether a change fixed the issue.
| Field | Type | Description |
|---|---|---|
status | ReinforcementLoopOutcomeStatus! | |
statusReason | String! | Why the issue has its status, as a code such as fixed_by_change or no_change_in_window. New codes may be added. |
statusEvidence | String | Why the issue has its status, as a sentence. Null when agent content access is denied. |
windowStart | DateTime! | Start of the window checked. |
windowEnd | DateTime! | End of the window checked. Equals fixedAt for a run started by a fix. |
reportedAt | DateTime! | When the report was stored. |
fixedBy | [ReinforcementLoopIssueFix!]! | The changes that fixed the issue, oldest first. Empty unless FIXED. |
ReinforcementLoopIssueStatusCause
ReinforcementLoopIssueStatusCauseEnum type. What changed an RL V2 issue's status, or what happened to it.
- User actions: MARK_FIXED, MARK_IN_PROGRESS, UNDO, TICKET_CREATED, TICKET_LINKED,
PR_DISPATCHED, IGNORED, UNIGNORED. - Draft PR events: PR_OPENED, PR_CLOSED (closed without a merge), DISPATCH_FAILED (the
workflow failed or never finished). - A ticket or PR webhook or poller, such as LINEAR_WEBHOOK or GITHUB_WEBHOOK.
- The regression watch (REGRESSED), and a dismissed or restored conversation.
| Value | Description |
|---|---|
MARK_FIXED | |
MARK_IN_PROGRESS | |
UNDO | |
TICKET_CREATED | |
TICKET_LINKED | |
PR_DISPATCHED | |
PR_LINKED | |
DISPATCH_POLLER | |
LINEAR_WEBHOOK | |
JIRA_WEBHOOK | |
SERVICENOW_WEBHOOK | |
GITHUB_WEBHOOK | |
REGRESSED | |
MATCH_DISMISSED | |
MATCH_RESTORED | |
BACKFILL | |
IGNORED | |
UNIGNORED | |
PR_OPENED | |
PR_CLOSED | |
DISPATCH_FAILED |
ReinforcementLoopIssueStatusChange
ReinforcementLoopIssueStatusChangeObject type. One entry of an RL V2 issue's status history: a status change or an event, such as a
user action or a draft PR closing. An event can leave the status as it was, and then
fromStatus equals toStatus. Label an entry by its cause.
| Field | Type | Description |
|---|---|---|
changeUuid | UUID! | |
createdTime | DateTime! | When the change or event happened. |
fromStatus | ReinforcementLoopIssueStatus! | |
toStatus | ReinforcementLoopIssueStatus! | |
cause | ReinforcementLoopIssueStatusCause! | |
user | UserBasicInfo | The person who acted. Null when no person did, such as a webhook without a matching user or the regression watch, and once that user is deleted. |
isMine | Boolean! | Made by the caller. |
linkUrl | String | The ticket, PR or pasted link behind the entry. An event links its own ticket or PR. A change to OPEN links only a Linear ticket or ServiceNow incident that closed without being done and so moved the issue. Null when the work has no link, such as a user action without a pasted link or a draft PR still running. |
linkLabel | String | The ticket key or PR number of linkUrl, such as AI-2098 or #3051. |
linkSource | ReinforcementLoopIssueFixSource | The system behind linkUrl. Null when linkUrl is. MANUAL is a link a user pasted. RL_PR is the issue's draft PR. |
conversationCount | Int | On a regression, the conversations counted against the fix. |
undoneAction | ReinforcementLoopIssueUndoAction | On an UNDO change, the user action it reverted. |
ReinforcementLoopIssueUndoAction
ReinforcementLoopIssueUndoActionEnum type. The user action that undoReinforcementLoopIssueStatus reverts.
| Value | Description |
|---|---|
MARK_FIXED | |
MARK_IN_PROGRESS |
ReinforcementLoopOutcomeStatus
ReinforcementLoopOutcomeStatusEnum type. Whether an RL outcomes run found that a change fixed the issue.
| Value | Description |
|---|---|
FIXED | |
NOT_FIXED | |
UNKNOWN |
ReinforcementLoopRunMode
ReinforcementLoopRunModeEnum type. Whether a reinforcement-loop run or issue is live work or a backtest.
| Value | Description |
|---|---|
LIVE | |
BACKTEST |
ReinforcementLoopTraceRef
ReinforcementLoopTraceRefObject type. One turn a reinforcement-loop issue cites in a conversation.
| Field | Type | Description |
|---|---|---|
traceId | String! | Trace id of the cited turn. |
turnIndex | Int! | Zero-based index of the cited turn within the conversation — matches the conversation API's turnIndex. |
traceStartTime | DateTime | Start bound for looking up this turn's trace — pass to getTraceTreeNodes' traceStartTime. Span event time (the trace's earliest span timestamp, padded by 5 minutes), resolved from the trace store at read time. Null when the trace can no longer be found. |
traceEndTime | DateTime | End bound for looking up this turn's trace — pass to getTraceTreeNodes' traceEndTime. Span event time (the trace's latest span timestamp, padded by 5 minutes), resolved from the trace store at read time. Null when the trace can no longer be found. |
ReinforcementLoopV2ConversationBucket
ReinforcementLoopV2ConversationBucketObject type. Distinct diagnosed conversations of an issue in one bucket, by conversation time.
| Field | Type | Description |
|---|---|---|
bucketStart | DateTime! | Midnight starting the bucket's day, with the series timeZone's offset. |
conversationCount | Int! |
ReinforcementLoopV2ConversationBucketSize
ReinforcementLoopV2ConversationBucketSizeEnum type. Bucket width of an RL V2 conversation series. DAY = one calendar day in the series'
timeZone.
| Value | Description |
|---|---|
DAY |
ReinforcementLoopV2ConversationCountSeries
ReinforcementLoopV2ConversationCountSeriesObject type. An issue's conversations per bucket of the list's [startTime, endTime) window.
| Field | Type | Description |
|---|---|---|
completeThrough | DateTime | Diagnosis has reached every conversation before this time; counts after it can still grow. It is an estimate: a conversation whose traces arrive late can still be added before it. Null for backtest issues, and when clustering or diagnosis has not started on the issue's Issue space. |
buckets | [ReinforcementLoopV2ConversationBucket!]! | One bucket per day of the window in the series timeZone, oldest first, zero-filled. The first and last can be partial days. A day across a daylight saving change is 23 or 25 hours long. They add up to conversationCountInWindow. |
ReinforcementLoopV2ConversationSeriesInput
ReinforcementLoopV2ConversationSeriesInputInput object type. How to split each issue's conversations in the list's window.
| Field | Type | Description |
|---|---|---|
bucketSize | ReinforcementLoopV2ConversationBucketSize! | |
timeZone | String | The IANA time zone whose calendar days the buckets follow, such as America/Chicago. Defaults to UTC. An unknown name fails the request. |
ReinforcementLoopV2DiagnosisCluster
ReinforcementLoopV2DiagnosisClusterObject type. An Issue cluster as the diagnosis run recorded it when the trigger fired.
A snapshot from the run's manifest. Name and description are the cluster's
at diagnosis time and survive a later rename or deletion.
| Field | Type | Description |
|---|---|---|
clusterUuid | UUID! | The cluster's id at diagnosis time. |
clusterKey | String! | The cluster's key within its Issue space. |
name | String! | The cluster's name at diagnosis time. |
description | String! | The cluster's description at diagnosis time. |
conversationCount | Int | Distinct conversations of the issue that matched this cluster, or on responsibleClusters, whose report named it responsible. Counted within the same workflow filter as the issue's conversationCount. Null on a conversation's clusters. |
ReinforcementLoopV2EmptyReason
ReinforcementLoopV2EmptyReasonEnum type. Why getReinforcementLoopV2Issues returned no nodes.
NO_ISSUE_SPACE = the agent has no Issue space; NO_ISSUES = the
account has no issue of the requested mode for this agent, before any
filter; NO_MATCHES = issues exist but none match the filters.
| Value | Description |
|---|---|
NO_ISSUE_SPACE | |
NO_ISSUES | |
NO_MATCHES |
ReinforcementLoopV2Issue
ReinforcementLoopV2IssueObject type. One RL V2 issue: cross-conversation identity plus its conversations.
| Field | Type | Description |
|---|---|---|
issueUuid | UUID! | The issue's public id — the handle the ticket and draft-PR mutations resolve, the issueUuid argument for a targeted re-fetch, and the issue_id the agent passes when it reports the issue again. |
issueSpaceUuid | UUID | The Issue space the issue belongs to; null once the space is deleted. |
agentName | String! | |
traceTableMcon | String! | |
mode | ReinforcementLoopRunMode! | Live issues and backtest issues never mix. |
title | String! | Current title: the newest report's. A placeholder when the caller cannot read agent content. |
description | String | Current description: the newest report's. Null when content is restricted. |
recommendation | String | Current recommendation: the newest report's. May be empty on a TRACES_ONLY issue. Null when content is restricted. |
configAccess | ReinforcementLoopConfigAccess! | What the newest report's text was written from. FULL on an issue with no report. Not subject to redaction. |
isDataIssue | Boolean! | True when the newest report says the agent acted reasonably but the data it got back was bad. False on an issue with no report. Not subject to redaction. |
priority | AgentHealthPriority | Impact bucket of impactScore, computed at read time: HIGH at 3 or more, MEDIUM at 1.5 or more, LOW above 0. An issue scoring 0 is LOW when a conversation of it ever had a wrong, unsupported, partial or missing answer, or when it has 3 or more conversations in the last 14 days, and HIDDEN otherwise. It always bands the score of the last 14 days, which is impactScore only when the list has neither startTime nor endTime. Null for an issue with no reports. Not subject to redaction. |
impactScore | Float | The Issue Impact Score: the sum of the impact scores of the issue's conversations in [startTime, endTime), by conversation time, at most the last 90 days of it, or in the last 14 days when the list has neither bound or is a backtest list. priority does not follow the range. Measured in bad conversations: 3 is about three conversations that went fully wrong, or six that went half wrong. Each conversation's impact shows its entries. Null for an issue with no reports. Not subject to redaction. |
rank | Int | The issue's place in its Issue space's top 10, 1 first. Null outside the top 10. An agent has an Issue space per workflow, or one for the whole agent. Issues rank by priority, then impactScore, then conversations counted in impactScore, then the worst of them, then the newest report. Ignored and HIDDEN issues are not ranked. A workflowName filter ranks on that workflow's reports. startTime and endTime rank the issues the list keeps that had a conversation between them, on their impactScore over that time. No other filter changes the rank. |
isNewToTop | Boolean! | In its Issue space's top 10 now, and not 7 days ago. With startTime or endTime, the earlier top ranks the same range moved 7 days back. |
reportedPriority | AgentHealthPriority | The highest priority the agent has reported for the issue. Never HIDDEN. Not subject to redaction. Deprecated: priority no longer reads it. Null once the agent stops reporting one.. |
groupingMetadata | GenericScalar | For the reinforcement-loop agent only; the UI never shows it. The free-form object the grouping agent saved with the newest report, read back so later runs reuse its grouping decisions. Null when the newest report carried none and when content is restricted. |
firstDetectedAt | DateTime! | The time of the issue's earliest conversation. |
lastSeenAt | DateTime! | The time of the issue's newest conversation; the sort key, newest first. |
conversationCount | Int! | Distinct conversations the issue was diagnosed in, in total; not clamped to conversationsFirst. |
conversationCountInWindow | Int | Distinct conversations the issue was diagnosed in whose conversation time is in [startTime, endTime). Conversation time is the start of the conversation's latest turn. A missing bound is open. The workflow filter applies. Only diagnosed conversations count, and conversations reported before this field existed have no conversation time. Null when the list has neither bound. |
conversationCountSeries | ReinforcementLoopV2ConversationCountSeries | conversationCountInWindow per bucket. Null unless conversationSeries is set. |
conversations | [ReinforcementLoopV2IssueConversation!]! | The newest conversationsFirst conversations, one entry each, newest report first. |
diagnosisClustersWithheldReason | RawContentWithheldReason | Why diagnosisClusters and responsibleClusters were withheld, or null when they were not. |
diagnosisClusters | [ReinforcementLoopV2DiagnosisCluster!]! | The Issue clusters the issue's conversations matched. Aggregated over all conversations, not only the served slice. Sorted by conversationCount descending, then name, then clusterKey. Name and description come from the newest run that matched the cluster. Empty when cluster content access is denied. |
responsibleClusters | [ReinforcementLoopV2DiagnosisCluster!]! | The Issue clusters the agent named as responsible for this issue, across all conversations. A conversation counts through its newest report; reports sent before the agent named clusters add none. Sorted and named like diagnosisClusters. Empty when cluster content access is denied. |
linearTicket | AgentHealthIssueLinearTicket | Linear ticket linked to this issue (at most one); null when none. |
jiraTicket | AgentHealthIssueJiraTicket | Jira ticket linked to this issue (at most one); null when none. |
serviceNowTicket | AgentHealthIssueServiceNowTicket | ServiceNow incident linked to this issue (at most one); null when none. |
draftPr | ReinforcementLoopDraftPrRef | The newest draft-PR workflow dispatch for this issue; null when never dispatched. |
issueReportUuid | UUID | The report record the title, description and recommendation come from. Send it back as issueReportUuid when leaving feedback. Null on an issue with no report. |
feedback | ReinforcementLoopIssueFeedback! | |
outcome | ReinforcementLoopIssueOutcome | What the newest RL outcomes run found: the run started by the issue's fix, or a daily run that found it fixed. Null when there is none. |
disposition | ReinforcementLoopIssueDisposition! | IGNORED once a user ignored the issue. Ignored issues still list here. |
dispositionReason | ReinforcementLoopIssueDispositionReason | Why the issue was ignored; null unless IGNORED. |
dispositionComment | String | The comment left when the issue was ignored. |
status | ReinforcementLoopIssueStatus! | Where the issue stands: OPEN, IN_PROGRESS or FIXED. |
fixedAt | DateTime | When the last fix was recorded. It stays set after the issue regressed or a user reopened the work. |
fixSource | ReinforcementLoopIssueFixSource | What recorded the last fix. |
fixLinkUrl | String | Link to the last fix, such as the merged PR or the completed ticket. |
regressedAt | DateTime | When the issue came back after its last fix. Null while the fix holds. |
inProgressAt | DateTime | When a user last marked the issue in progress. It stays set after a fix, like inProgressLinkUrl. The flag counts as work only when it is after fixedAt, or when there is no fix. |
inProgressLinkUrl | String | The link a user gave when marking the issue in progress. |
statusHistory | [ReinforcementLoopIssueStatusChange!]! | Status changes, and user actions and ticket or PR events that left the status as it was, newest first. History starts when status history shipped. Read only when selected. |
undoAction | ReinforcementLoopIssueUndoAction | The user's last Mark fixed or Mark in progress, while undoReinforcementLoopIssueStatus can still revert it. Null when there is nothing to undo: after an undo, or once a later fix, ticket, draft PR or regression cleared it. |
regressionConversations | [ReinforcementLoopV2IssueConversation!]! | The newest conversationsFirst conversations that count against the last fix: those that started 24 hours or more after it, less the dismissed ones. Newest conversation first. Empty without a fix. Not narrowed by the workflow filter. |
regressionConversationCount | Int | How many conversations count against the last fix. Two or more regress a Fixed issue. Null without a fix. |
dismissedConversations | [ReinforcementLoopV2IssueConversation!]! | The conversations a customer rated as not belonging to the issue. They don't count against a fix. Empty without a fix. Not narrowed by the workflow filter. |
ReinforcementLoopV2IssueConnection
ReinforcementLoopV2IssueConnectionObject type. One page of RL V2 issues.
| Field | Type | Description |
|---|---|---|
nodes | [ReinforcementLoopV2Issue!]! | This page's issues, in orderBy order. |
pageInfo | ReinforcementLoopV2IssuePageInfo! | Pagination information. |
emptyReason | ReinforcementLoopV2EmptyReason | Why nodes is empty. Null when nodes has entries, and on a page whose cursor ran past a non-empty result set. |
viewerIsStaff | Boolean! | Whether the caller counts as Monte Carlo staff: their feedback is hidden from customers and they can't ignore issues. |
ReinforcementLoopV2IssueConversation
ReinforcementLoopV2IssueConversationObject type. One conversation a reinforcement-loop issue was diagnosed in.
Backed by the newest report of the issue for this conversation.
| Field | Type | Description |
|---|---|---|
reportUuid | UUID! | The report record this row is. |
conversationId | String! | |
workflowName | String | Workflow of the conversation. Null is the no-workflow scope — the agent's spans carry no workflow attribute. An empty string is a separate, explicitly empty-named workflow; neither ever means 'all workflows'. |
materialization | String | How the issue shows up in this conversation, rendered by the agent. Null when the caller cannot read agent content. |
traceRefs | [ReinforcementLoopTraceRef!]! | The turns the diagnosis cites; may be empty. |
reportedAt | DateTime! | When the report was ingested. |
runUuid | UUID! | The diagnosis run that reported this conversation. |
diagnosisClustersWithheldReason | RawContentWithheldReason | Why diagnosisClusters and responsibleClusters were withheld, or null when they were not. |
diagnosisClusters | [ReinforcementLoopV2DiagnosisCluster!]! | The Issue clusters that qualified this conversation for diagnosis, as the run recorded them, in manifest order. Empty when cluster content access is denied. |
responsibleClusters | [ReinforcementLoopV2DiagnosisCluster!]! | The diagnosisClusters the agent named as responsible for this issue, in manifest order. Empty for reports sent before the agent named them, and when cluster content access is denied. |
impact | ReinforcementLoopConversationImpact! | How bad this conversation was. Its cluster entries are left out when cluster content access is denied. |
ReinforcementLoopV2IssueOrder
ReinforcementLoopV2IssueOrderEnum type. A sort key of getReinforcementLoopV2Issues.
RANK = each Issue space's top issues by rank, then every other issue.
PRIORITY = the served priority: CRITICAL, HIGH, MEDIUM, LOW, then HIDDEN
(only with includeHidden), then issues with no report. Within a priority, the
higher impactScore comes first. CONVERSATION_COUNT = most
conversations first. It is the conversationCount the node reports, so a
workflow filter narrows it. LAST_SEEN_AT = newest first. FIXED_AT = the newest fix
first, then issues with no fix. An issue keeps its fixedAt after the fix ends, so
filter on status FIXED to list current fixes only.
| Value | Description |
|---|---|
RANK | |
PRIORITY | |
CONVERSATION_COUNT | |
LAST_SEEN_AT | |
FIXED_AT |
ReinforcementLoopV2IssuePageInfo
ReinforcementLoopV2IssuePageInfoObject type. Forward-only pagination info for getReinforcementLoopV2Issues.
| Field | Type | Description |
|---|---|---|
hasNextPage | Boolean! | Whether more issues follow this page. |
endCursor | String | Cursor resuming after this page's last node; null on an empty page. |
ReinforcementLoopWorkflowScope
ReinforcementLoopWorkflowScopeEnum type. Which workflow scope an issue read covers.
ALL_WORKFLOWS = every workflow of the agent, each node carrying its own
workflowName; NO_WORKFLOW = only issues with no workflow at all (the agent's
spans carry no workflow attribute); NAMED = only the workflow given in
workflowName.
The scope is its own argument rather than a null/absent/value distinction on
workflowName, because a null argument value is indistinguishable from an
omitted one on this API layer — so the no-workflow scope needs a name it can
be asked for by.
Omitting the scope keeps each query's default inference: a workflowName
narrows to that workflow, its absence spans every workflow. New
workflow-scoped reads should take this enum instead of overloading
omission.
| Value | Description |
|---|---|
ALL_WORKFLOWS | |
NO_WORKFLOW | |
NAMED |
Related types
AgentHealthIssueJiraTicket, AgentHealthIssueLinearTicket, AgentHealthIssueServiceNowTicket, AgentHealthPriority, DateTime, GenericScalar, GithubActionTriggerDispatchPrState, GithubActionTriggerDispatchStatus, RawContentWithheldReason, ReinforcementLoopFeedbackPriorityReason, ReinforcementLoopFeedbackRating, ReinforcementLoopFeedbackReason, ReinforcementLoopIssueDispositionReason, ReinforcementLoopIssueStatus, UUID, UserBasicInfo
getSimilarConversations (query)
getSimilarConversations is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Find similar conversations, nearest first. Returns an empty list when the anchor has no embedding.
Arguments
| Argument | Type | Description |
|---|---|---|
agentName | String! | Cortex or Genie agent name |
traceTableMcon | String! | Trace table or platform agent MCON |
conversationId | String! | Anchor conversation ID |
lookbackDays | Int | Candidate lookback in days, from 1 to 30 Default: 3. |
first | Int | Maximum results, from 1 to 100 Default: 10. |
filters | SimilarConversationFiltersInput | Optional candidate filters |
Returns
[SimilarConversation!]!
Example
query GetSimilarConversations($agentName: String!, $traceTableMcon: String!, $conversationId: String!) {
getSimilarConversations(agentName: $agentName, traceTableMcon: $traceTableMcon, conversationId: $conversationId) {
conversationId
distance
}
}Types used only by getSimilarConversations
getSimilarConversationsSimilarConversation
SimilarConversationObject type. A conversation ranked by semantic similarity to an anchor conversation.
| Field | Type | Description |
|---|---|---|
conversationId | String! | Matching conversation ID |
distance | Float! | Cosine distance from 0 to 2; smaller means more similar |
SimilarConversationFiltersInput
SimilarConversationFiltersInputInput object type. Candidate filters applied before similarity ranking.
| Field | Type | Description |
|---|---|---|
hasErrors | Boolean | True requires errors, false requires no errors, null allows either |
minTotalTokens | Int | Inclusive minimum total tokens |
maxTotalTokens | Int | Inclusive maximum total tokens |
clusterKeys | [String!] | Match any listed cluster; requires clusteringSpaceUuid |
clusteringSpaceUuid | UUID | Clustering space for clusterKeys |
evalType | String | Evaluation dimension for score bounds |
evalMonitorUuid | UUID | Evaluation monitor for score bounds |
minEvalScore | Float | Inclusive minimum latest evaluation score |
maxEvalScore | Float | Inclusive maximum latest evaluation score |
Related types
getToolCallOverview (query)
getToolCallOverview is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get aggregate tool-call metrics over tool spans for a time range: total tool calls, average calls per trace, tool error rate, and the most-invoked tool with its share of calls. Optionally includes comparison to the previous period.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetToolCallOverviewInput! |
Returns
ToolCallOverviewMetricsWithComparison
Example
query GetToolCallOverview($input: GetToolCallOverviewInput!) {
getToolCallOverview(input: $input) {
totalToolCalls
avgCallsPerTrace
toolErrorRate
topToolName
topToolSharePct
}
}Types used only by getToolCallOverview
getToolCallOverviewGetToolCallOverviewInput
GetToolCallOverviewInputInput object type. Input parameters for getToolCallOverview query.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent (aiagent object type) to query |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (exclusive) |
includePreviousPeriodComparison | Boolean | Include comparison to previous period of equal length (default: true) Default: true. |
filters | TraceFiltersInput | Optional filters to refine results (model, workflow and task at span level; conversation resolves whole traces) |
segmentFilter | TraceSegmentFilterInput | Optional segment dimension filter. Restricts the tool spans counted to those whose dimension (MODEL, WORKFLOW, or TASK) matches one of the values (OR logic within the values list); an empty values list disables the filter. Omitted or null counts all tool spans. Note: MODEL is rarely populated on tool spans, as tools are not LLM calls. |
ToolCallOverviewMetrics
ToolCallOverviewMetricsObject type.
| Field | Type | Description |
|---|---|---|
totalToolCalls | Int! | |
avgCallsPerTrace | Float | |
toolErrorRate | Float | |
topToolName | String | |
topToolSharePct | Float |
ToolCallOverviewMetricsWithComparison
ToolCallOverviewMetricsWithComparisonObject type.
| Field | Type | Description |
|---|---|---|
totalToolCalls | Int! | |
avgCallsPerTrace | Float | |
toolErrorRate | Float | |
topToolName | String | |
topToolSharePct | Float | |
prevPeriod | ToolCallOverviewMetrics |
Related types
DateTime, TraceFiltersInput, TraceSegmentFilterInput
getToolCallTimeSeries (query)
getToolCallTimeSeries is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get per-tool time series metrics over tool spans. Returns time-bucketed, gap-filled series segmented by tool name — call volume, latency percentiles, or error count/rate depending on the metric group. Series are capped at the top-N tools by call count unless an explicit toolNames set is given.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetToolCallTimeSeriesInput! |
Returns
[ToolCallTimeSeriesType]
Example
query GetToolCallTimeSeries($input: GetToolCallTimeSeriesInput!) {
getToolCallTimeSeries(input: $input) {
metric
toolName
segment
}
}Types used only by getToolCallTimeSeries
getToolCallTimeSeriesGetToolCallTimeSeriesInput
GetToolCallTimeSeriesInputInput object type. Input parameters for getToolCallTimeSeries query.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent (aiagent object type) to query |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (exclusive) |
bucketSize | TraceBucketSize! | Size of time buckets (MINUTE, HOUR, DAY, WEEK) |
metricGroup | ToolCallMetricGroup | Metric group to return. Each group maps to a set of metrics: VOLUME (call count), LATENCY (avg/p50/p95/p99), ERRORS (error count + error rate). Deprecated: use metricGroups instead. |
metricGroups | [ToolCallMetricGroup!] | Metric groups to return from one read, with duplicate metrics returned once. Provide a non-empty list or metricGroup, exclusively. The groups are those of metricGroup. |
topN | Int | Cap the number of returned tool series to the top-N tools by call count. Ignored when toolNames is provided. Default: 10. |
toolNames | [String!] | Optional explicit set of tool names to return; overrides topN when provided. |
filters | TraceFiltersInput | Optional filters to refine results (model, workflow and task at span level; conversation resolves whole traces) |
segmentFilter | TraceSegmentFilterInput | Optional segment dimension filter (MODEL, WORKFLOW, or TASK). When supplied, series are grouped by that dimension — one series per segment value (aggregated across tools), with toolName null and segment set; only spans whose dimension matches one of the values (OR logic) are counted, and an empty values list disables the filter. A requested value with no tool spans in the window yields no series (rather than an empty line). Omitted or null returns one series per tool (toolName set, segment null). Note: MODEL is rarely populated on tool spans, as tools are not LLM calls. |
ToolCallMetricGroup
ToolCallMetricGroupEnum type. Metric groups for tool-call time series queries.
Each group maps to a set of individual ToolCallTimeSeriesMetric values via
TOOL_CALL_METRIC_GROUP_TO_METRICS.
| Value | Description |
|---|---|
VOLUME | |
LATENCY | |
ERRORS |
ToolCallTimeSeriesMetric
ToolCallTimeSeriesMetricEnum type. Per-tool span-level metrics for tool-call time series queries.
Unlike TraceTimeSeriesMetric (trace-grained, read from agent_traces), these
are computed over tool-call spans (is_tool_call=true) and segmented by tool
name (the span name). A tool span errors when its status code is 2.
| Value | Description |
|---|---|
CALL_COUNT | |
LATENCY_AVG | |
LATENCY_P50 | |
LATENCY_P95 | |
LATENCY_P99 | |
ERROR_COUNT | |
ERROR_RATE |
ToolCallTimeSeriesType
ToolCallTimeSeriesTypeObject type. Time series for a single tool-call metric, one object per (metric, series).
Without a segmentFilter, one object is returned per (metric, tool) — a chart
renders one line/area per toolName. With a segmentFilter, one object is
returned per (metric, segment value), aggregated across tools — segment
carries the dimension value (e.g. a workflow name) and toolName is null.
| Field | Type | Description |
|---|---|---|
metric | ToolCallTimeSeriesMetric! | The tool-call metric this series represents |
toolName | String | The tool this series represents; null when a segment dimension is active |
segment | String | The segment dimension value this series represents when segmentFilter is supplied — e.g. a workflow name, task name, or model identifier (not the MODEL/WORKFLOW/TASK enum key); null when no segment dimension is active. |
buckets | [TraceTimeSeriesBucketType!]! | Time-bucketed data points (gap-filled; null value where no data) |
Related types
DateTime, TraceBucketSize, TraceFiltersInput, TraceSegmentFilterInput, TraceTimeSeriesBucketType
getToolDetail (query)
getToolDetail is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get per-tool detail (last invoked, average latency, invocation count, tables accessed) for a given tool MCON. lastInvoked, avgLatencySeconds, and invocationCount are computed over a fixed trailing 7-day window.
Arguments
| Argument | Type | Description |
|---|---|---|
mcon | String! | Trace table or platform agent MCON that scopes the lookup. |
agentName | String! | Name of the agent whose tool is being looked up. |
toolName | String! | Name of the tool to retrieve detail for. |
Returns
ToolDetail
Example
query GetToolDetail($mcon: String!, $agentName: String!, $toolName: String!) {
getToolDetail(mcon: $mcon, agentName: $agentName, toolName: $toolName) {
lastInvoked
avgLatencySeconds
invocationCount
}
}Types used only by getToolDetail
getToolDetailToolDetail
ToolDetailObject type. Per-tool statistics derived from agent traces.
| Field | Type | Description |
|---|---|---|
lastInvoked | DateTime! | Timestamp of the most recent invocation in the lookup window. |
avgLatencySeconds | Float | Average latency in seconds over measured invocations in the lookup window (null when no invocation is measured). |
invocationCount | Int! | Number of times this tool was invoked in the lookup window. |
tablesAccessed | [LineageGraphNode!]! | Lineage graph nodes for catalogued tables accessed by this tool. Returns an empty list when no upstream tables are recorded for the tool, or when every recorded upstream table has no catalog entry. |
Related types
getTopTools (query)
getTopTools is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get ranked per-tool aggregate stats over tool spans for a time range: call count and share, average/p95 latency, and error count/rate. Sorted by call count descending. Powers the top-tools bar chart and the tools legend.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetTopToolsInput! |
Returns
[TopTool]
Example
query GetTopTools($input: GetTopToolsInput!) {
getTopTools(input: $input) {
toolName
callCount
sharePct
avgLatencySeconds
p95LatencySeconds
errorCount
errorRate
segment
toolTotal
}
}Types used only by getTopTools
getTopToolsGetTopToolsInput
GetTopToolsInputInput object type. Input parameters for getTopTools query.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent (aiagent object type) to query |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (exclusive) |
limit | Int | Maximum number of tools to return, ranked by call count Default: 10. |
filters | TraceFiltersInput | Optional filters to refine results (model, workflow and task at span level; conversation resolves whole traces) |
segmentFilter | TraceSegmentFilterInput | Optional segment dimension filter (MODEL, WORKFLOW, or TASK). When supplied, each tool is broken down by segment value: results gain a populated segment and toolTotal (the tool's total across segments), and tools are ranked by toolTotal rather than callCount. Only spans whose dimension matches one of the values (OR logic) are counted; an empty values list disables the filter. Omitted or null returns one row per tool (segment and toolTotal null). Note: MODEL is rarely populated on tool spans, as tools are not LLM calls. |
TopTool
TopToolObject type.
| Field | Type | Description |
|---|---|---|
toolName | String! | |
callCount | Int! | |
sharePct | Float! | |
avgLatencySeconds | Float | |
p95LatencySeconds | Float | |
errorCount | Int! | |
errorRate | Float | |
segment | String | |
toolTotal | Int |
Related types
DateTime, TraceFiltersInput, TraceSegmentFilterInput
getTraceExplanation (query)
getTraceExplanation is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Generate an AI explanation of a single trace. Each call regenerates — explanations are not persisted.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetTraceExplanationInput! |
Returns
TraceExplanationResult
Example
query GetTraceExplanation($input: GetTraceExplanationInput!) {
getTraceExplanation(input: $input) {
traceId
summary
modelId
}
}Types used only by getTraceExplanation
getTraceExplanationGetTraceExplanationInput
GetTraceExplanationInputInput object type. Input for getTraceExplanation query.
TraceExplanationResult
TraceExplanationResultObject type. Result of getTraceExplanation: an AI-authored summary of one trace.
| Field | Type | Description |
|---|---|---|
traceId | String! | Trace id |
summary | String! | Explanation of the trace — a single comprehensive markdown paragraph covering what the agent was doing, the steps it took, errors it encountered, slow calls, and anything else worth flagging. Identifiers are wrapped in inline code; the paragraph does not use headings, fenced code blocks, or lists. |
modelId | String! | Identifier of the LLM that produced this explanation |
Related types
getTraceOverview (query)
getTraceOverview is a query in the Monte Carlo GraphQL API, in Agent traces and evaluations. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get aggregated overview metrics for agent traces. Returns total counts, latency percentiles, and token usage for a time range. Optionally includes comparison to the previous period of equal duration.
Arguments
| Argument | Type | Description |
|---|---|---|
input | GetTraceOverviewInput! |
Returns
TraceOverviewMetricsWithComparison
Example
query GetTraceOverview($input: GetTraceOverviewInput!) {
getTraceOverview(input: $input) {
totalTraces
totalConversations
avgLatency
p50Latency
p95Latency
p99Latency
totalTokens
totalPromptTokens
totalCompletionTokens
errorCount
errorPercentage
}
}Types used only by getTraceOverview
getTraceOverviewGetTraceOverviewInput
GetTraceOverviewInputInput object type. Input parameters for GetTraceOverview query.
| Field | Type | Description |
|---|---|---|
agentName | String! | Agent name to filter by |
traceTableMcon | String! | MCON of the trace table or platform agent (aiagent object type) to query |
startTime | DateTime! | Start of time range (inclusive) |
endTime | DateTime! | End of time range (exclusive) |
includePreviousPeriodComparison | Boolean | Include comparison to previous period of equal length (default: true) Default: true. |
filters | TraceFiltersInput | Optional filters to refine results |
segmentFilter | TraceSegmentFilterInput | Optional segment dimension filter. Filters traces by one dimension (MODEL, WORKFLOW, or TASK) using OR logic within the values list. Omitted or null returns all traces. |
TraceFeedbackCounts
TraceFeedbackCountsObject type.
| Field | Type | Description |
|---|---|---|
positive | Int! | |
negative | Int! | |
unrated | Int! | Traces whose feedback has no rating |
withComment | Int! | Traces whose newest feedback carries a comment, at any rating |
negativePercentage | Float | Percentage of negative among positive and negative traces. Null when no trace has a rating. |
TraceOverviewMetrics
TraceOverviewMetricsObject type.
| Field | Type | Description |
|---|---|---|
totalTraces | Int! | |
totalConversations | Int! | Number of conversations with messages or tool calls from traces matching the selected filters and time range. The end time is excluded; totalTraces currently includes the end time. |
avgLatency | Float | |
p50Latency | Float | |
p95Latency | Float | |
p99Latency | Float | |
totalTokens | BigInt | |
totalPromptTokens | BigInt | |
totalCompletionTokens | BigInt | |
errorCount | Int | |
errorPercentage | Float | |
feedback | TraceFeedbackCounts | Traces by their newest end-user feedback. Null when feedback is not available for the agent. |
TraceOverviewMetricsWithComparison
TraceOverviewMetricsWithComparisonObject type.
| Field | Type | Description |
|---|---|---|
totalTraces | Int! | |
totalConversations | Int! | Number of conversations with messages or tool calls from traces matching the selected filters and time range. The end time is excluded; totalTraces currently includes the end time. |
avgLatency | Float | |
p50Latency | Float | |
p95Latency | Float | |
p99Latency | Float | |
totalTokens | BigInt | |
totalPromptTokens | BigInt | |
totalCompletionTokens | BigInt | |
errorCount | Int | |
errorPercentage | Float | |
feedback | TraceFeedbackCounts | Traces by their newest end-user feedback. Null when feedback is not available for the agent. |
prevPeriod | TraceOverviewMetrics |
Related types
BigInt, DateTime, TraceFiltersInput, TraceSegmentFilterInput
Source: The GraphQL API reference
This page is generated from the GraphQL schema on each release. Changes made in ReadMe are overwritten.
