From c09e7d1017b15197d33a83096d2db6e8a5b4bf32 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Tailland?= Date: Mon, 31 Aug 2026 15:04:26 +0200 Subject: [PATCH] Follow the supply agent's rename Its Keycloak client and audience scope changed name; the peer entry and the environment variables that point at it move with them. Co-Authored-By: Claude Opus 5 --- README.md | 2 +- k8s/configmap.yaml | 2 +- k8s/deployment.yaml | 2 +- src/catalogue_agent/agent.py | 4 ++-- src/catalogue_agent/config.py | 4 ++-- src/catalogue_agent/peers.py | 14 +++++++------- 6 files changed, 14 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index 8eb2b48..e1ff23a 100644 --- a/README.md +++ b/README.md @@ -137,7 +137,7 @@ and the A2A call to the supply agent work, and `k8s/` deploys through Flux. ## Deployment ``` -gitea.sttlab.eu/stt/classic-models-agent-catalogue:v0.3.2 +gitea.sttlab.eu/stt/classic-models-agent-catalogue:v0.4.0 ``` gitea's own registry rather than ghcr, so the image sits beside the source it diff --git a/k8s/configmap.yaml b/k8s/configmap.yaml index 6fc4ec6..084e8d6 100644 --- a/k8s/configmap.yaml +++ b/k8s/configmap.yaml @@ -26,4 +26,4 @@ data: CATALOGUE_PUBLIC_URL: http://catalog-agent.agents.svc.cluster.local:8080/ # The peer's Service name, overriding the default in config.py — set here so # the rename took effect without rebuilding an image. - CATALOGUE_APPROVISIONNEMENT_URL: http://supply-agent.agents.svc.cluster.local:8080/ + CATALOGUE_SUPPLY_URL: http://supply-agent.agents.svc.cluster.local:8080/ diff --git a/k8s/deployment.yaml b/k8s/deployment.yaml index 5db6c74..ff40b6c 100644 --- a/k8s/deployment.yaml +++ b/k8s/deployment.yaml @@ -30,7 +30,7 @@ spec: # repo is public, so the pull needs no credentials — which removes an # imagePullSecret that would otherwise have to be created by hand in # this namespace and kept in step with a GitHub token. - image: gitea.sttlab.eu/stt/classic-models-agent-catalogue:v0.3.2 + image: gitea.sttlab.eu/stt/classic-models-agent-catalogue:v0.4.0 ports: - name: http containerPort: 8080 diff --git a/src/catalogue_agent/agent.py b/src/catalogue_agent/agent.py index fa436f4..f196185 100644 --- a/src/catalogue_agent/agent.py +++ b/src/catalogue_agent/agent.py @@ -53,7 +53,7 @@ How to work: bears on a pricing or discontinuation decision. You never act on orders. - State figures as the tools returned them. If a tool returns nothing, say so rather than estimating. -- When a decision depends on availability, ask Approvisionnement with +- When a decision depends on availability, ask Supply with `check_availability`. It answers; it does not hand back the stock table, and you must not infer availability from the catalog's own quantity field. - Never recommend discontinuing a reference without asking. A reference about to @@ -288,7 +288,7 @@ class CatalogueAgent: is how an agent becomes a proxy onto its neighbours. This one asks a single question of a single peer. """ - peer = peers(self._settings)["approvisionnement"] + peer = peers(self._settings)["supply"] settings, exchanger = self._settings, self._exchanger async def check_availability(productcode: str) -> str: diff --git a/src/catalogue_agent/config.py b/src/catalogue_agent/config.py index f7020af..a75428b 100644 --- a/src/catalogue_agent/config.py +++ b/src/catalogue_agent/config.py @@ -39,8 +39,8 @@ class Settings(BaseSettings): # An A2A call returns an answer, not data. Consulting this one is how the # agent learns whether a reference is about to be reordered before it # recommends dropping it — without gaining any sight of the supply domain. - approvisionnement_url: str = "http://supply-agent.agents.svc.cluster.local:8080/" - approvisionnement_scope: str = "classic-models-agent-approvisionnement-audience" + supply_url: str = "http://supply-agent.agents.svc.cluster.local:8080/" + supply_scope: str = "classic-models-agent-supply-audience" mcp_sales_scope: str = "mcp-sales-audience token-exchange-broker-audience" # --- inference ---------------------------------------------------------- diff --git a/src/catalogue_agent/peers.py b/src/catalogue_agent/peers.py index 58c5e3b..161739c 100644 --- a/src/catalogue_agent/peers.py +++ b/src/catalogue_agent/peers.py @@ -1,7 +1,7 @@ """Calling another agent, as a tool the model can reach for. The rule this agent lives by: **an A2A call returns an answer, not data.** It -asks Approvisionnement "can S10_1949 be promised?" and receives a decision. It +asks Supply "can S10_1949 be promised?" and receives a decision. It never gains read access to whatever that agent can see, and it must not — the whole per-domain scoping rests on a specialist answering rather than handing over its records. @@ -11,7 +11,7 @@ A generic one would let the model reach any peer with any prompt, which is how an agent becomes a proxy onto its neighbours. The peer's token is minted per call, for that peer alone, from the end user's -own token. A token for Approvisionnement is refused by every other agent, so a +own token. A token for Supply is refused by every other agent, so a prompt injection that talks this agent into consulting the wrong peer fails at the realm. """ @@ -42,16 +42,16 @@ class Peer: def peers(settings: Settings) -> dict[str, Peer]: - """Approvisionnement, and nothing else. + """Supply, and nothing else. The design has this agent consult it before a discontinuation decision: a reference that is about to be reordered is not a reference to drop. """ return { - "approvisionnement": Peer( - "approvisionnement", - settings.approvisionnement_url, - settings.approvisionnement_scope, + "supply": Peer( + "supply", + settings.supply_url, + settings.supply_scope, ) }