Skip to main content
Glama

Search LCA database

engine_search
Read-onlyIdempotent

Search an LCA database for processes, systems, flows or methods. The database is the one named by source, else this connection's default. kind scopes to processes, systems, flows, projects, methods (m<N> refs), or all (processes, systems and flows). query='*' (or an empty string) enumerates everything of the given kind (one page of limit, plus the true total). With kind='flow', flow_type (elementary / product / waste) filters the results; with kind='process', process_type (unit_process / system_process) filters by type and geography (a location code) by place. Returns typed refs (p1, e1, f1; a system hit is an e<N> engine-catalog ref, not a workspace s<N>) valid for the session, accepted by engine_get and lca_run_assessment. scope_ref (any engine ref such as p3/e1/m2 from an earlier result) searches the database that ref came from instead, for comparing across databases; refs minted that way stay bound to that database.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "<query>"
    },
    "name": "engine_search"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNoWhat to search for. 'all' queries processes, systems, and flows in parallel. 'project' lists openLCA projects — a project is addressed by its name, which `lca_import_project` takes. 'method' lists the LCIA methods whose name contains every word of `query` (`*` lists all); not part of 'all'.all
limitNoMax results per page (default 20).
queryYesFree-text query, matched word by word against dataset names, categories and location codes — there is no meaning-based matching, so the nouns a dataset is named by (a material, a process, a product) find more than a description of the use (`polypropylene injection moulding`, not `plastic plate`). On an openLCA database a place matches by name or code (`Switzerland`, `CH`); to keep only one place, on any engine, use `geography`. When no hit contains every word, the closest partial matches come back, labelled as such. Use `*` (or an empty string) to list everything of the given `kind` — the way to enumerate what a database contains.
offsetNoStart index for pagination (default 0).
sourceNoName of the source, as `lca_get(kind='sources')` lists it (case-insensitive). Omitted: this connection's default source. Not combined with `scope_ref`, which picks the database a ref came from.
flow_typeNoOnly meaningful when kind=flow.
geographyNoOnly meaningful when kind=process. A location code (`CH`, `RER`, `GLO`, `RoW`, `CA-QC`); only processes located exactly there are returned. On an ecoinvent engine this is the only way to choose a place: a place written into `query` filters nothing there.
scope_refNoOptional. An engine ref (`p`/`e`/`f`/`m`) whose database to search instead of the active connection. Omit to search the active connection.
process_typeNoOnly meaningful when kind=process. Restrict to unit processes vs aggregated (system) processes.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • removedInput schema / properties / engine
      Removed value: -{
      -  "description": "Name of the engine database, as `lca_get(kind='engines')` lists it (case-insensitive). Omitted: this connection's default engine. Not combined with `scope_ref`, which picks the database a ref came from.",
      -  "maxLength": 255,
      -  "minLength": 1,
      -  "type": "string"
      -}
    • addedInput schema / properties / source
      Added value: +{
      +  "description": "Name of the source, as `lca_get(kind='sources')` lists it (case-insensitive). Omitted: this connection's default source. Not combined with `scope_ref`, which picks the database a ref came from.",
      +  "maxLength": 255,
      +  "minLength": 1,
      +  "type": "string"
      +}
  2. Changed2 schema fields changed
    • addedInput schema / properties / geography
      Added value: +{
      +  "description": "Only meaningful when kind=process. A location code (`CH`, `RER`, `GLO`, `RoW`, `CA-QC`); only processes located exactly there are returned. On an ecoinvent engine this is the only way to choose a place: a place written into `query` filters nothing there.",
      +  "maxLength": 100,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • changedInput schema / properties / query / description
      Previous value: -"Free-text query, matched word by word against dataset names, categories and location codes — there is no meaning-based matching, so the nouns a dataset is named by (a material, a process, a product) find more than a description of the use (`polypropylene injection moulding`, not `plastic plate`). A place matches by name or code (`Switzerland`, `CH`). When no hit contains every word, the closest partial matches come back, labelled as such. Use `*` (or an empty string) to list everything of the given `kind` — the way to enumerate what a database contains."New value: +"Free-text query, matched word by word against dataset names, categories and location codes — there is no meaning-based matching, so the nouns a dataset is named by (a material, a process, a product) find more than a description of the use (`polypropylene injection moulding`, not `plastic plate`). On an openLCA database a place matches by name or code (`Switzerland`, `CH`); to keep only one place, on any engine, use `geography`. When no hit contains every word, the closest partial matches come back, labelled as such. Use `*` (or an empty string) to list everything of the given `kind` — the way to enumerate what a database contains."
  3. Changed2 schema fields changed
    • changedInput schema / properties / kind / description
      Previous value: -"What to search for. 'all' queries processes, systems, and flows in parallel. 'project' lists openLCA projects — a project is addressed by its name, which `lca_import_project` takes."New value: +"What to search for. 'all' queries processes, systems, and flows in parallel. 'project' lists openLCA projects — a project is addressed by its name, which `lca_import_project` takes. 'method' lists the LCIA methods whose name contains every word of `query` (`*` lists all); not part of 'all'."
    • changedInput schema / properties / kind / enum
      Previous value: -[
      -  "process",
      -  "system",
      -  "flow",
      -  "project",
      -  "all"
      -]New value: +[
      +  "process",
      +  "system",
      +  "flow",
      +  "project",
      +  "method",
      +  "all"
      +]
  4. Changed2 schema fields changed
    • changedInput schema / properties / kind / description
      Previous value: -"What to search for. 'all' queries processes, systems, and flows in parallel."New value: +"What to search for. 'all' queries processes, systems, and flows in parallel. 'project' lists openLCA projects — a project is addressed by its name, which `lca_import_project` takes."
    • changedInput schema / properties / kind / enum
      Previous value: -[
      -  "process",
      -  "system",
      -  "flow",
      -  "all"
      -]New value: +[
      +  "process",
      +  "system",
      +  "flow",
      +  "project",
      +  "all"
      +]
  5. Changed1 schema field changed
    • changedInput schema / properties / query / description
      Previous value: -"Free-text query against names/categories. Use `*` (or an empty string) to list everything of the given `kind` — the way to enumerate what a database contains."New value: +"Free-text query, matched word by word against dataset names, categories and location codes — there is no meaning-based matching, so the nouns a dataset is named by (a material, a process, a product) find more than a description of the use (`polypropylene injection moulding`, not `plastic plate`). A place matches by name or code (`Switzerland`, `CH`). When no hit contains every word, the closest partial matches come back, labelled as such. Use `*` (or an empty string) to list everything of the given `kind` — the way to enumerate what a database contains."
  6. Changed3 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / offset / maximum
      Added value: +9007199254740991
  7. Changed1 schema field changed
    • addedInput schema / properties / engine
      Added value: +{
      +  "description": "Name of the engine database, as `lca_get(kind='engines')` lists it (case-insensitive). Omitted: this connection's default engine. Not combined with `scope_ref`, which picks the database a ref came from.",
      +  "maxLength": 255,
      +  "minLength": 1,
      +  "type": "string"
      +}
  8. First observed

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover safety (readOnly, idempotent, non-destructive), yet the description adds real behavioral detail: enumeration returns 'one page of `limit`, plus the true total', refs are typed and valid only for the session, refs minted via `scope_ref` stay bound to that database, and partial matches come back labelled when no exact hit exists. The substantive gap is the exact result shape beyond the ref tokens, which matters since there is no output schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded and dense: purpose first, then enumeration mode, then per-kind filters, then the ref/scope semantics that determine downstream call validity. It runs long and repeats some parameter details already captured in the schema, but no sentence is pure filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 9-parameter, cross-database search with no output schema, the definition covers enumeration, filtering, pagination, ref lifetime and cross-database scoping. What is left unstated is the full returned record shape (fields besides the ref token) and any result ordering, which an agent would otherwise have to probe.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, and the description mostly restates what the schema already documents for `kind`, `flow_type`, `process_type` and `geography`. It does add one genuinely new semantic: `source` and `scope_ref` are mutually exclusive, with `scope_ref` overriding by pinning the database a ref came from.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb+resource: 'Search an LCA database for processes, systems, flows or methods', then narrows scope via `kind`. It is clearly distinguished from engine_get and lca_run_assessment, which are named as the consumers of the refs this tool returns, so an agent knows this is the discovery step, not the retrieval step.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives concrete when-to-use rules: `query='*'` to enumerate a database, `scope_ref` when comparing across databases, `geography` rather than `query` to filter to a single place on an ecoinvent engine. It does not contrast itself with other searchish siblings (e.g. lca_search_factors), so an agent must infer that boundary, but within its own domain the guidance is explicit and actionable.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources