Skip to main content

agents.json

The file agents.json is how an agent introduces itself to the web app. The file is an object. Each key is an agent's id, and each value describes one agent, so one file can describe several agents. The agent serves it at /agents.json, and a user can connect any other agent by entering the address of a server that serves such a file.

The fields below are generated from the schema that the web app validates the file with, in frontend/src/lib/state/copilot.ts.

Agent​

The value of each key of the file.

objectno other properties

Properties

  • idstring

    The agent's id. It defaults to the key of the object. The web app refuses to add an agent whose id or name matches one that the user already has

  • namestringrequired

    The name that the interface shows

  • descriptionstringrequired

    A sentence about the agent

  • imagestring (uri)

    The agent's avatar. A relative address is resolved against the address of the file

  • linkstring (uri)

    A page about the agent

  • hasStreamingboolean

    A shortcut for the feature streaming. It replaces the entry of that feature in features, whichever value the entry has

  • hasDocumentsboolean

    A shortcut for the feature file-upload. It replaces the entry of that feature in features, whichever value the entry has

  • hasFunctionCallingboolean

    A shortcut for the features widget-dashboard-select, widget-dashboard-search and widget-global-search. It replaces their entries in features, whichever value the entries have

  • endpointsobjectrequiredno other properties

    Where the web app sends requests. Each endpoint is a URL, and a relative address is resolved against the address of agents.json

    3 nested properties
    • upload_docsstring (uri)

      Where the web app sends documents that the user attaches to a chat with this agent, as a multipart form with the files in the field files, in batches of at most 157286400 bytes. An agent without it does not accept documents

    • querystring (uri)

      Where the web app sends questions

    • feedbackstring (uri)

      Where the web app posts a thumbs up or down on an answer, when the agent has the feature feedback. The body has vote, which is thumbs_up or thumbs_down, tags, user_comment, ai_response, user_prompt and trace_id

  • featuresmap<string, boolean | object>

    What the agent can do and which settings it offers. A key is either true, which switches a feature on, or an object that describes a setting that the user can change

  • modelsobject[]

    The models that a user can pick. When the list is empty or missing, the web app uses the options of a select setting named model

    2 nested properties
    • idstringrequired

      The id of the model

    • namestringrequired

      The name that the interface shows

  • skillsobject[]

    Skills that the agent provides. The web app sends the slug and the description of the skill that a user invokes in selected_skills

    2 nested properties
    • slugstringrequired

      The word that the user types after a slash to invoke the skill

    • descriptionstringrequired

      What the skill does, which the web app sends with the slug

Feature setting​

The object that a key of features holds when it describes a setting that the user can change.

objectno other properties

Properties

  • labelstringrequired

    The name that the options menu shows

  • type"toggle" | "text" | "select"

    The kind of control: toggle, which is the default, text or select

  • defaultboolean | string

    The starting value: a boolean for a toggle and a string for the other types. A select without a default starts on its first option

  • descriptionstring

    An explanation of the setting

  • placeholderstring

    The hint of a text setting

  • optionsobject[]

    The choices of a select

    2 nested properties
    • labelstringrequired

      The name that the choice shows

    • valuestringrequired

      The value that the web app sends when the choice is selected

Features​

The web app knows these keys of features. A key set to true switches the feature on.

  • streaming

    The agent answers with a stream of events

  • file-upload

    The user can attach files with the extensions .pdf, .txt, .md, .markdown, .docx, .html, .csv, .xlsx, .png, .jpg, .jpeg

  • widget-dashboard-select

    The widgets and tabs of the current dashboard can be mentioned in a question, every widget has a button that adds it to the chat, and the dashboard's widgets are sent to the agent as context

  • widget-dashboard-search

    Any widget of the catalog can be mentioned in a question, not only the widgets of the dashboard

  • widget-global-search

    The web app also sends the rest of the widget catalog in the extra tier of the request, so the agent can find widgets that are not on the dashboard

  • mcp-tools

    The web app sends the tools of the user's MCP servers and of the FINOS Workspace in the tools of the request

  • agent-orchestration

    The user can let the agent hand work to other connected agents

  • feedback

    The chat shows thumbs up and down and posts them to the feedback endpoint

  • speech-to-text

    The chat shows a microphone button

Example​

This is the file that a running the agent answers with. The agent's exporter writes it with DEFAULT_MODEL, AGENT_MODELS and AGENT_TRANSCRIBE_MODEL set, and the agent builds it in agent/src/routes/agents.ts.

{
  "default_agent": {
    "name": "Agent",
    "description": "An open-source, model-agnostic agent for the FINOS Workspace",
    "endpoints": {
      "query": "/v1/query"
    },
    "skills": [
      {
        "slug": "html-report",
        "description": "Generate an HTML report using FINOS Workspace's reporting capabilities."
      },
      {
        "slug": "html-table",
        "description": "When creating or styling a table widget for FINOS Workspace, follow these rules."
      },
      {
        "slug": "html-chart",
        "description": "When creating or styling a chart widget (line/area/scatter) for FINOS Workspace, follow these rules."
      }
    ],
    "features": {
      "streaming": true,
      "widget-dashboard-select": true,
      "widget-dashboard-search": true,
      "widget-global-search": true,
      "mcp-tools": true,
      "file-upload": true,
      "speech-to-text": true,
      "prompt-suggestions": {
        "label": "Follow-up Suggestions",
        "default": true,
        "description": "Show follow-up prompt suggestions after each response."
      },
      "model": {
        "label": "Model",
        "type": "select",
        "default": "<provider>:<model>",
        "description": "Select the LLM model to use.",
        "options": [
          {
            "label": "<provider>:<model>",
            "value": "<provider>:<model>"
          }
        ]
      }
    }
  }
}
  • features.model is present only when DEFAULT_MODEL or AGENT_MODELS is set.
  • features.speech-to-text is present only when AGENT_TRANSCRIBE_MODEL is set.

Loading​

  • The web app requests the file at the address that the user entered or, for the default agent, at the address of its urls.ai setting. A user can add request headers, such as an Authorization header, and the app sends them with every request to the agent, including this one.
  • A 401 means that the agent refused the request, a 404 means that the file does not exist, and a file that does not match the schema is reported as an invalid agents file.
  • The web app merges the entry default_agent of the default agent into its own definition of the default agent, so the models, skills and settings that the agent declares appear in the interface without a change to the app. The Admin → Roles dialog uses the same entry to list the models that a role can be granted.
  • The settings travel in the workspace_options of the request that the query protocol describes.