{
  "tools": [
    {
      "name": "search_legal_sources",
      "title": "Search Laki.ai Finnish legal and tax sources",
      "description": "Discover Finnish statutes, case law, preparatory works, and administrative or tax guidance by legal concept, title, abbreviation, or section reference. Use several distinct queries for multi-issue questions and filters only when they improve precision. Results are candidate locators with ids, titles, source types, snippets, heading paths when available, and truncation guidance; call read_document before relying on or citing them.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "queries": {
            "type": "array",
            "description": "Free-text query strings used to search legal sources. Pass multiple distinct legal-concept queries in one call so Laki.ai can run them in parallel; results are returned per query.",
            "minItems": 1,
            "maxItems": 5,
            "items": {
              "type": "string",
              "maxLength": 1000
            }
          },
          "type": {
            "type": "array",
            "description": "Optional source type filters. Omit or pass an empty array to search all source types. Supported values are statute, case_law, administrative_guidance, and preparatory_works. Note the returned sourceType differs for two filters: case_law results return sourceType \"judgment\", and preparatory_works results return sourceType \"government_proposal\".",
            "items": {
              "type": "string",
              "enum": [
                "statute",
                "case_law",
                "administrative_guidance",
                "preparatory_works"
              ]
            }
          },
          "mode": {
            "type": "string",
            "description": "How to search. hybrid (default) fuses keyword/full-text and semantic relevance and suits most discovery queries. fts prefers exact Finnish full-text and name matching, including quoted phrases, statute names, and section references. semantic runs only meaning-based vector search and is best when the exact wording is unknown. preparatory_works has no semantic index, so it returns nothing under semantic.",
            "enum": [
              "hybrid",
              "fts",
              "semantic"
            ]
          },
          "inForceOnly": {
            "type": "boolean",
            "description": "When true, return only statutes currently in force.",
            "default": false
          },
          "asOfDate": {
            "type": "string",
            "description": "Optional YYYY-MM-DD date. When provided, return the statute version in force on that date."
          },
          "limit": {
            "type": "integer",
            "description": "Maximum number of results to return.",
            "minimum": 1,
            "maximum": 10,
            "default": 5
          }
        },
        "required": [
          "queries"
        ],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Search Laki.ai Finnish legal and tax sources",
        "readOnlyHint": true,
        "openWorldHint": false,
        "destructiveHint": false
      }
    },
    {
      "name": "read_document",
      "title": "Read Laki.ai legal source",
      "description": "Read one or more source, section, or content-block ids. For every statute-section read with related-source stubs enabled, always pass concise research context on that same call: either the user's question or another short statement of the legal issue and desired related-source angle. No context is retained between calls. Context may be omitted for whole-document reads or when includeRelatedSourceStubs is false. Successful documents include their id, title, source type, exact citation, complete blocks with ids and block citations, and optional related-source leads; per-id failures remain alongside successful reads. Prefer the most specific returned citation and copy it verbatim. Related-source records and search snippets are leads only: read their ids before relying on or citing them. Navigate a too_large document with get_table_of_contents or search_within_documents.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "ids": {
            "type": "array",
            "description": "Laki.ai source ids returned by search_legal_sources, read_document contentBlocks, or related-source stubs. Pass several ids in one call so Laki.ai can read them in parallel.",
            "minItems": 1,
            "maxItems": 10,
            "items": {
              "type": "string",
              "maxLength": 256
            }
          },
          "includeRelatedSourceStubs": {
            "type": "boolean",
            "description": "When true (default), include compact related-source stubs for statute section reads only. Set false to omit them for this read.",
            "default": true
          },
          "context": {
            "type": "string",
            "description": "Concise research context used only to determine which related-source leads are relevant for this call. For every statute-section read with includeRelatedSourceStubs enabled, always pass either the user's question or another short statement of the legal issue and desired related-source angle on that same call; no context is retained between calls. Omit only for reads that do not request related-source filtering.",
            "maxLength": 2000
          }
        },
        "required": [
          "ids"
        ],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Read Laki.ai legal source",
        "readOnlyHint": true,
        "openWorldHint": false,
        "destructiveHint": false
      }
    },
    {
      "name": "get_statute_section_history",
      "title": "Get statute section version history",
      "description": "Trace one Finnish statute section across versions. Returns the statute and section identity, version-specific section ids and citations, in-force dates, text when available, amending statutes, preparatory works, rationale leads, and paging state. Use it for temporal questions or amendment provenance, read linked source ids for deeper evidence, and state gaps when a historical text is unavailable.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "Statute section content-block id from search_legal_sources or read_document, e.g. act_sc_2006-624_2025-0561__chp_22__sec_1.",
            "maxLength": 256
          },
          "startFromIndex": {
            "type": "integer",
            "description": "Zero-based index into the genuine section-change history. Omit or pass 0 for the latest changes.",
            "minimum": 0,
            "default": 0
          }
        },
        "required": [
          "id"
        ],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Get statute section version history",
        "readOnlyHint": true,
        "openWorldHint": false,
        "destructiveHint": false
      }
    },
    {
      "name": "get_table_of_contents",
      "title": "Get table of contents for Laki.ai legal sources",
      "description": "Navigate one or more already-identified sources by nested heading and section ids. The requested depth caps the returned outline and the result states that deeper entries may be omitted. Returned ids are locators, not evidence; pass the relevant ids to read_document before relying on or citing them.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "ids": {
            "type": "array",
            "description": "One or more already-identified Laki.ai ids returned by search_legal_sources, read_document, related-source stubs, or another in-document navigation tool. Pass ids to read_document before relying on locator-only results.",
            "minItems": 1,
            "maxItems": 10,
            "items": {
              "type": "string",
              "maxLength": 256
            }
          },
          "depth": {
            "type": "integer",
            "description": "Maximum nested outline depth to return. Default 2. Use higher values only when deeper nested structure is needed.",
            "minimum": 1,
            "maximum": 6,
            "default": 2
          }
        },
        "required": [
          "ids"
        ],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Get table of contents for Laki.ai legal sources",
        "readOnlyHint": true,
        "openWorldHint": false,
        "destructiveHint": false
      }
    },
    {
      "name": "search_within_documents",
      "title": "Search inside Laki.ai legal sources",
      "description": "Search only inside supplied source ids. Hybrid combines full-text and semantic matching, fts suits exact Finnish terms and section references, and semantic suits conceptual passages. Results retain document identity, readable match ids, snippets or section keys, scores, embedding activity, and an explicit truncation flag. Matches are locators, not evidence; read returned ids before relying on or citing them.",
      "inputSchema": {
        "type": "object",
        "properties": {
          "ids": {
            "type": "array",
            "description": "One or more already-identified Laki.ai ids returned by search_legal_sources, read_document, related-source stubs, or another in-document navigation tool. Pass ids to read_document before relying on locator-only results.",
            "minItems": 1,
            "maxItems": 10,
            "items": {
              "type": "string",
              "maxLength": 256
            }
          },
          "query": {
            "type": "string",
            "description": "Search text. Use natural-language concepts for semantic or hybrid mode and Finnish full-text terms for fts. Pure semantic mode accepts at most 200 characters; fts and hybrid accept at most 500, and hybrid uses the first 200 for its semantic leg.",
            "maxLength": 500
          },
          "mode": {
            "type": "string",
            "description": "How to search within the supplied documents. hybrid (default) fuses full-text and semantic relevance and suits most queries. fts is Finnish full-text over the document text — best for exact terms and section references. semantic is meaning-based — best when the exact wording is unknown.",
            "enum": [
              "hybrid",
              "fts",
              "semantic"
            ]
          }
        },
        "required": [
          "ids",
          "query"
        ],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Search inside Laki.ai legal sources",
        "readOnlyHint": true,
        "openWorldHint": false,
        "destructiveHint": false
      }
    },
    {
      "name": "get_source_coverage",
      "title": "Get source coverage",
      "description": "Describe which Finnish and EU legal sources are currently searchable in Laki.ai MCP, which important sources are not yet searchable, and how to find the available material.",
      "inputSchema": {
        "type": "object",
        "properties": {},
        "required": [],
        "additionalProperties": false
      },
      "securitySchemes": [
        {
          "type": "oauth2",
          "scopes": [
            "legal_sources:search"
          ]
        }
      ],
      "_meta": {
        "securitySchemes": [
          {
            "type": "oauth2",
            "scopes": [
              "legal_sources:search"
            ]
          }
        ]
      },
      "annotations": {
        "title": "Get source coverage",
        "readOnlyHint": true,
        "destructiveHint": false,
        "openWorldHint": false
      }
    }
  ]
}
