AnalysisPlan

interface AnalysisPlan : AnalysisPlanProperties

This is the plan for analysis of assistant's calls. Stored in call.analysis.

Properties

Link copied to clipboard
abstract var structuredDataPrompt: String

This is the prompt that's used to extract structured data from the call. The output is stored in call.analysis.structuredData.
Disabled by default.
You can use this standalone or in combination with structuredDataSchema. If both are provided, they are concatenated into appropriate instructions.

Link copied to clipboard

This is how long the request is tried before giving up. When request times out, call.analysis.structuredData will be empty. Increasing this timeout will delay the end of call report.
Default is 5 seconds.

Link copied to clipboard
abstract var successEvaluationPrompt: String

This is the prompt that's used to evaluate if the call was successful. The output is stored in call.analysis.successEvaluation.
Default is "You are an expert call evaluator. You will be given a transcript of a call and the system prompt of the AI participant. Determine if the call was successful based on the objectives inferred from the system prompt. DO NOT return anything except the result.".
Set to '' or 'off' to disable.
You can use this standalone or in combination with successEvaluationRubric. If both are provided, they areconcatenated into appropriate instructions.

Link copied to clipboard

This is how long the request is tried before giving up. When request times out, call.analysis.successEvaluation will be empty. Increasing this timeout will delay the end of call report.
Default is 5 seconds.

Link copied to clipboard

This enforces the rubric of the evaluation. The output is stored in call.analysis.successEvaluation.
Options include:

  • 'NumericScale': A scale of 1 to 10.
  • 'DescriptiveScale': A scale of Excellent, Good, Fair, Poor.
  • 'Checklist': A checklist of criteria and their status.
  • 'Matrix': A grid that evaluates multiple criteria across different performance levels.
  • 'PercentageScale': A scale of 0% to 100%.
  • 'LikertScale': A scale of Strongly Agree, Agree, Neutral, Disagree, Strongly Disagree.
  • 'AutomaticRubric': Automatically break down evaluation into several criteria, each with its own score.
  • 'PassFail': A simple 'true' if call passed, 'false' if not. For 'Checklist' and 'Matrix', provide the criteria in successEvaluationPrompt.
    Default is 'PassFail' if successEvaluationPrompt is not provided, and null if successEvaluationPrompt is provided.
    You can use this standalone or in combination with successEvaluationPrompt. If both are provided, they are concatenated into appropriate instructions.

  • Link copied to clipboard
    abstract var summaryPrompt: String

    This is the prompt that's used to summarize the call. The output is stored in call.analysis.summary.
    Default is "You are an expert note-taker. You will be given a transcript of a call. Summarize the call in 2-3 sentences. DO NOT return anything except the summary.".
    Set to '' or 'off' to disable.

    Link copied to clipboard
    abstract var summaryRequestTimeoutSeconds: Double

    This is how long the request is tried before giving up. When request times out, call.analysis.summary will be empty. Increasing this timeout will delay the end of call report.
    Default is 5 seconds.

    Functions

    Link copied to clipboard
    abstract fun structuredDataSchema(block: StructuredDataSchema.() -> Unit)

    This enforces the schema of the structured data. This output is stored in call.analysis.structuredData. Complete guide on JSON Schema can be found here. Disabled by default. You can use this standalone or in combination with structuredDataPrompt. If both are provided, they are concatenated into appropriate instructions.