Skip to main content
Glama

Build linked product system

lca_compose_linked

Build a product system as an explicit process network with supply edges. Every member and supply edge is sent in one call. Structure only; no LCIA runs. For a list of materials and quantities, lca_compose_assembly is simpler. A link may route a waste output to its treatment (consumer_ref outputs it, provider_ref treats it). ref_process_ref is the functional unit's process and also appears in member_process_refs. It is validated against the database; if valid it is saved and system_ref is returned for lca_run_assessment. If invalid, the response lists errors[], missing_required[] and warnings[] and nothing is saved; a corrected call carries the complete system. dry_run: true validates without saving. A tool error (not an invalid result) means the engine is unavailable. Takes p<N>/f<N> refs; UUIDs are not accepted. Requires the user's own writable engine; an unreachable member blocks the build. The product_system_authoring skill (load_skill) covers build order and failures.

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": {
      "workspace": "<workspace>",
      "ref_process_ref": "<ref_process_ref>",
      "member_process_refs": "<member_process_refs>"
    },
    "name": "lca_compose_linked"
  }
}

Input Schema

NameRequiredDescriptionDefault
linksNoSupply edges connecting members: a supplier's product into a consumer's input, or a consumer's waste output into its treatment.
titleNoHuman title for the authored system.
sourceNoName of the source, as `lca_get(kind='sources')` lists it (case-insensitive). Omitted: this connection's default source.
dry_runNoWhen true, validate ONLY — return the envelope without persisting (and without a confirmation prompt). Default false: a valid system is built and its s-ref returned in this one call.
workspaceYesName of the workspace to work in, as `lca_get(kind='workspaces')` lists it (backticks optional). Named on every call: several conversations can share one connection, and each names its own workspace. The connection's default is often an empty sandbox rather than the user's work.
ref_flow_refNo`f<N>` ref of the reference product flow (a product OUTPUT of the ref process). Omitted, it is the reference process's own quantitative reference.
target_amountNoFunctional-unit amount (default 1.0).
process_phasesNoThe life-cycle phase of each member process you tag, by its ref: one entry per process, giving a phase or a module (a process named twice, or not in `member_process_refs`, is an error). To leave a process untagged, leave it out of the list; it then counts only under 'unassigned'.
temporal_scopeNoTemporal scope of the system (e.g. '2020-2024', 'Reference year 2022').
cutoff_criteriaNoExplicit cutoff criteria (e.g. 'Mass cutoff 1%; energy cutoff 1%'). Nothing is recorded when omitted.
declared_phasesNoThe life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (beyond the system boundary: benefits and loads of reuse, recycling and recovery, shown beside the total — EN 15804 module D).
excluded_phasesNoPhases deliberately left out, each with an optional short reason (e.g. {phase: 'end_of_life', reason: 'outside the study goal'}). A phase in neither list reads 'not declared', never 'excluded'.
ref_process_refYes`p<N>` ref of the reference process (the functional unit). It must also be listed in `member_process_refs`.
target_unit_refNoThe functional unit's unit, when it is NOT the reference exchange's own unit (which is derived for you). A unit NAME as the engine spells it ('t', 'kg', 'MJ'), resolved against the reference flow's unit group — NOT a ref: there is no `u<N>` kind, and an f/p/s ref here is rejected.
geographical_scopeNoExplicit geographical scope (e.g. 'Switzerland'). Overrides location codes derived from member processes.
process_data_typesNoWhat each member process's data are, by its ref: primary (measured by the user for this product) or secondary (a database's generic data). A process from a published database (BAFU, US LCA Commons, ecoinvent) is always secondary; one from the user's own database is secondary unless the user measured it and says primary. A process authored through Aevia left out stays unset, and the primary-data share then reads 'not recorded'. Ask the user whether a process's data are measured by them; record the answer here or later with set_data_type.
member_process_refsYes`p<N>` refs of every process in the system — include the reference process.
functional_unit_descriptionNoFree-text description of the functional unit (e.g. 'One house, 160 m², 50-year service life').

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • changedInput schema / properties / declared_phases / description
      Previous value: -"The life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (beyond end of life: benefits and loads of reuse, recycling and recovery, shown beside the total — EN 15804 module D)."New value: +"The life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (beyond the system boundary: benefits and loads of reuse, recycling and recovery, shown beside the total — EN 15804 module D)."
    • changedInput schema / properties / process_phases / items / properties / module / description
      Previous value: -"This process's phase tag. EN 15804 module (A1-A3 product, A4-A5 transport/installation, B1-B7 use, C1-C4 end of life, D beyond end of life: reuse, recycling, recovery), only when the study follows EN 15804; sets its phase, must match `phase`. A1-A3 for aggregated data."New value: +"This process's phase tag. EN 15804 module (A1-A3 product, A4-A5 transport/installation, B1-B7 use, C1-C4 end of life, D beyond the system boundary: reuse, recycling, recovery), only when the study follows EN 15804; sets its phase, must match `phase`. A1-A3 for aggregated data."
    • changedInput schema / properties / process_phases / items / properties / phase / description
      Previous value: -"This process's phase tag. Phase: production (materials, manufacture), distribution (transport, installation), use (operation, upkeep, energy/water), end_of_life (dismantling, waste, disposal), beyond_boundary (beyond end of life: reuse, recycling, recovery; shown beside the total, not in it); omit = untagged."New value: +"This process's phase tag. Phase: production (materials, manufacture), distribution (transport, installation), use (operation, upkeep, energy/water), end_of_life (dismantling, waste, disposal), beyond_boundary (beyond the system boundary: reuse, recycling, recovery; shown beside the total, not in it); omit = untagged."
  2. 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.",
      -  "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.",
      +  "maxLength": 255,
      +  "minLength": 1,
      +  "type": "string"
      +}
  3. Changed1 schema field changed
    • addedInput schema / properties / process_data_types
      Added value: +{
      +  "description": "What each member process's data are, by its ref: primary (measured by the user for this product) or secondary (a database's generic data). A process from a published database (BAFU, US LCA Commons, ecoinvent) is always secondary; one from the user's own database is secondary unless the user measured it and says primary. A process authored through Aevia left out stays unset, and the primary-data share then reads 'not recorded'. Ask the user whether a process's data are measured by them; record the answer here or later with set_data_type.",
      +  "items": {
      +    "properties": {
      +      "data_type": {
      +        "description": "primary: data the user measured for this product (never a published database's process); secondary: a database's generic data.",
      +        "enum": [
      +          "primary",
      +          "secondary"
      +        ],
      +        "type": "string"
      +      },
      +      "process_ref": {
      +        "description": "p-ref of a member process (one of the system's members).",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "process_ref",
      +      "data_type"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  4. Changed3 schema fields changed
    • changedInput schema / properties / declared_phases / description
      Previous value: -"The life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (EN 15804 module D: credits and loads of reuse, recycling and recovery)."New value: +"The life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (beyond end of life: benefits and loads of reuse, recycling and recovery, shown beside the total — EN 15804 module D)."
    • changedInput schema / properties / process_phases / items / properties / module / description
      Previous value: -"This process's phase tag. EN 15804 module (A1-A3 product, A4-A5 transport/installation, B1-B7 use, C1-C4 end of life, D beyond the boundary: reuse, recycling, recovery); sets its phase, must match `phase`. A1-A3 for aggregated data."New value: +"This process's phase tag. EN 15804 module (A1-A3 product, A4-A5 transport/installation, B1-B7 use, C1-C4 end of life, D beyond end of life: reuse, recycling, recovery), only when the study follows EN 15804; sets its phase, must match `phase`. A1-A3 for aggregated data."
    • changedInput schema / properties / process_phases / items / properties / phase / description
      Previous value: -"This process's phase tag. Phase: production (materials, manufacture), distribution (transport, installation), use (operation, upkeep, energy/water), end_of_life (dismantling, waste, disposal), beyond_boundary (module D: credits and loads of reuse, recycling, recovery; shown beside the total, not in it); omit = untagged."New value: +"This process's phase tag. Phase: production (materials, manufacture), distribution (transport, installation), use (operation, upkeep, energy/water), end_of_life (dismantling, waste, disposal), beyond_boundary (beyond end of life: reuse, recycling, recovery; shown beside the total, not in it); omit = untagged."
  5. Changed4 schema fields changed
    • changedInput schema / properties / cutoff_criteria / description
      Previous value: -"Explicit cutoff criteria (e.g. 'Mass cutoff 1%; energy cutoff 1%'). Overrides the scope-derived default."New value: +"Explicit cutoff criteria (e.g. 'Mass cutoff 1%; energy cutoff 1%'). Nothing is recorded when omitted."
    • addedInput schema / properties / declared_phases
      Added value: +{
      +  "description": "The life-cycle phases this system covers — declare what its contents hold. Omitted on an assembly: production. Omitted on a linked system: production when its reference is a product it makes, else nothing. Omitted when any part carries a phase tag: nothing is declared, and the tags state the phases they name. Phases: production (materials and manufacture), distribution (transport to site, installation), use (operation, maintenance, replacement, operational energy and water), end_of_life (dismantling, waste treatment, disposal), beyond_boundary (EN 15804 module D: credits and loads of reuse, recycling and recovery).",
      +  "items": {
      +    "enum": [
      +      "production",
      +      "distribution",
      +      "use",
      +      "end_of_life",
      +      "beyond_boundary"
      +    ],
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / excluded_phases
      Added value: +{
      +  "description": "Phases deliberately left out, each with an optional short reason (e.g. {phase: 'end_of_life', reason: 'outside the study goal'}). A phase in neither list reads 'not declared', never 'excluded'.",
      +  "items": {
      +    "properties": {
      +      "phase": {
      +        "enum": [
      +          "production",
      +          "distribution",
      +          "use",
      +          "end_of_life",
      +          "beyond_boundary"
      +        ],
      +        "type": "string"
      +      },
      +      "reason": {
      +        "description": "Why it is outside the boundary.",
      +        "maxLength": 300,
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "phase"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / process_phases
      Added value: +{
      +  "description": "The life-cycle phase of each member process you tag, by its ref: one entry per process, giving a phase or a module (a process named twice, or not in `member_process_refs`, is an error). To leave a process untagged, leave it out of the list; it then counts only under 'unassigned'.",
      +  "items": {
      +    "properties": {
      +      "module": {
      +        "description": "This process's phase tag. EN 15804 module (A1-A3 product, A4-A5 transport/installation, B1-B7 use, C1-C4 end of life, D beyond the boundary: reuse, recycling, recovery); sets its phase, must match `phase`. A1-A3 for aggregated data.",
      +        "enum": [
      +          "A1",
      +          "A2",
      +          "A3",
      +          "A1-A3",
      +          "A4",
      +          "A5",
      +          "B1",
      +          "B2",
      +          "B3",
      +          "B4",
      +          "B5",
      +          "B6",
      +          "B7",
      +          "C1",
      +          "C2",
      +          "C3",
      +          "C4",
      +          "D"
      +        ],
      +        "type": "string"
      +      },
      +      "phase": {
      +        "description": "This process's phase tag. Phase: production (materials, manufacture), distribution (transport, installation), use (operation, upkeep, energy/water), end_of_life (dismantling, waste, disposal), beyond_boundary (module D: credits and loads of reuse, recycling, recovery; shown beside the total, not in it); omit = untagged.",
      +        "enum": [
      +          "production",
      +          "distribution",
      +          "use",
      +          "end_of_life",
      +          "beyond_boundary"
      +        ],
      +        "type": "string"
      +      },
      +      "process_ref": {
      +        "description": "`p<N>` of a member process — one of `member_process_refs`.",
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "process_ref"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  6. Changed1 schema field changed
    • changedInput schema / properties / ref_flow_ref / description
      Previous value: -"`f<N>` ref of the reference product flow (a product OUTPUT of the ref process)."New value: +"`f<N>` ref of the reference product flow (a product OUTPUT of the ref process). Omitted, it is the reference process's own quantitative reference."
  7. Changed6 schema fields changed
    • changedInput schema / properties / links / description
      Previous value: -"Supply edges connecting members."New value: +"Supply edges connecting members: a supplier's product into a consumer's input, or a consumer's waste output into its treatment."
    • changedInput schema / properties / links / items / properties / amount / description
      Previous value: -"Quantity consumed (in the consumer input's unit)."New value: +"Quantity on this edge (in the consumer exchange's unit)."
    • changedInput schema / properties / links / items / properties / consumer_input_index / description
      Previous value: -"When the consumer has 2+ input exchanges of `flow_ref`, the 0-based index (ordered by exchange id) of which one this edge feeds. Omit when unambiguous."New value: +"When the consumer has 2+ input exchanges of `flow_ref` (for a waste: 2+ output exchanges of it), the 0-based index (ordered by exchange id) of which one this edge pins. Omit when unambiguous."
    • changedInput schema / properties / links / items / properties / consumer_ref / description
      Previous value: -"`p<N>` of the process consuming the flow."New value: +"`p<N>` of the process consuming the flow — for a waste flow, the process that OUTPUTS the waste."
    • changedInput schema / properties / links / items / properties / flow_ref / description
      Previous value: -"`f<N>` of the product flow routed along this edge."New value: +"`f<N>` of the product flow routed along this edge, or of a waste routed from its generator to its treatment."
    • changedInput schema / properties / links / items / properties / provider_ref / description
      Previous value: -"`p<N>` of the upstream process supplying the flow."New value: +"`p<N>` of the upstream process supplying the flow — for a waste flow, its treatment (reference = that waste as an input)."
  8. Changed1 schema field changed
    • changedInput schema / properties / workspace / description
      Previous value: -"Name of the workspace to work in, as `lca_get(kind='workspaces')` lists it (backticks optional). Named on every call: several conversations can share one connection, and each names its own workspace."New value: +"Name of the workspace to work in, as `lca_get(kind='workspaces')` lists it (backticks optional). Named on every call: several conversations can share one connection, and each names its own workspace. The connection's default is often an empty sandbox rather than the user's work."
  9. Changed4 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
    • removedInput schema / properties / links / items / additionalProperties
      Removed value: -false
    • addedInput schema / properties / links / items / properties / consumer_input_index / maximum
      Added value: +9007199254740991
  10. Changed3 schema fields 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.",
      +  "maxLength": 255,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / workspace
      Added value: +{
      +  "description": "Name of the workspace to work in, as `lca_get(kind='workspaces')` lists it (backticks optional). Named on every call: several conversations can share one connection, and each names its own workspace.",
      +  "maxLength": 255,
      +  "minLength": 1,
      +  "type": "string"
      +}
    • changedInput schema / required
      Previous value: -[
      -  "ref_process_ref",
      -  "member_process_refs"
      -]New value: +[
      +  "workspace",
      +  "ref_process_ref",
      +  "member_process_refs"
      +]
  11. First observed

TDQS

A4.2/5.0
Behavior3/5

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

Annotations already declare this is a non-read-only, non-destructive, non-idempotent, closed-world write, and the description adds substantial context beyond them: DB validation before save, `system_ref` returned, invalid results return `errors[]`/`missing_required[]`/`warnings[]` with nothing saved, and a tool error means the engine is unavailable. It also discloses prerequisites (user's own writable engine, unreachable member blocks the build) that annotations cannot express. It stops short of describing system size limits or partial-failure semantics beyond the all-or-nothing rule.

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 with purpose and the sibling distinction, then failure modes, then prerequisites — a sensible order with little waste. It is dense with backticked refs and mid-paragraph caveats, which costs a little readability but each sentence carries operational information.

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

Completeness5/5

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

For an 18-parameter authoring tool with no output schema, the description covers the return value (`system_ref`), the failure envelope, validation vs persistence, and the engine prerequisite. Nothing an agent needs to call it correctly or handle its result is missing.

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% and the field descriptions are already rich, so the description only needs to reinforce. It does add a cross-parameter invariant ("`ref_process_ref` is the functional unit's process and also appears in `member_process_refs`") and the waste-routing interpretation of `consumer_ref`/`provider_ref`, but both are also stated in the schema, and the `p<N>`/`f<N>`-not-UUIDs rule is the main genuinely additive point. Baseline 3 fits.

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?

The first two sentences name a specific verb and resource ("Build a product system as an explicit process network with supply edges"), scope it ("Every member and supply edge is sent in one call") and bound it ("Structure only; no LCIA runs"). It explicitly contrasts with the sibling `lca_compose_assembly`, so an agent can pick between them without opening a schema.

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

Usage Guidelines5/5

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

Selects the alternative by condition: "For a list of materials and quantities, `lca_compose_assembly` is simpler." It also states when to use `dry_run: true` (validate without saving) and where to go for sequencing help (`load_skill` with `product_system_authoring`), covering when and when-not.

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