Agentenwerk
memory compact
Takes a message history and a character budget and returns a shortened history together with a full account of what it cost.
POST https://agent.halowerk.com/v1/memory-compactEingaben
| Feld | Typ | Pflicht | Beschreibung |
|---|---|---|---|
| messages | array | Ja | The conversation in order, oldest first. |
| budget_chars | integer | Ja | Character budget for the sum of all returned message contents. |
| keep_last_n | integer | Nein | How many of the most recent messages are protected. |
| keep_roles | array | Nein | Roles whose messages are protected. |
| duplicate_threshold | number | Nein | Word-overlap ratio from which a later message of the same role counts as a near-duplicate of an earlier one. |
| max_message_chars | integer | Nein | Length to which unprotected survivors are trimmed in the trim stage. |
Vollständiges Eingabeschema anzeigen
{
"type": "object",
"required": [
"messages",
"budget_chars"
],
"additionalProperties": false,
"properties": {
"messages": {
"type": "array",
"minItems": 2,
"maxItems": 200,
"description": "The conversation in order, oldest first.",
"items": {
"type": "object",
"required": [
"role",
"content"
],
"additionalProperties": false,
"properties": {
"role": {
"type": "string",
"enum": [
"system",
"user",
"assistant",
"tool"
],
"description": "Speaker role."
},
"content": {
"type": "string",
"minLength": 1,
"maxLength": 8000,
"description": "Message text."
},
"id": {
"type": "string",
"maxLength": 128,
"description": "Optional caller-side identifier, echoed unchanged."
},
"pin": {
"type": "boolean",
"default": false,
"description": "If true this message is protected: never trimmed, never dropped."
}
}
}
},
"budget_chars": {
"type": "integer",
"minimum": 100,
"maximum": 400000,
"description": "Character budget for the sum of all returned message contents."
},
"keep_last_n": {
"type": "integer",
"minimum": 0,
"maximum": 50,
"default": 5,
"description": "How many of the most recent messages are protected."
},
"keep_roles": {
"type": "array",
"maxItems": 4,
"default": [
"system"
],
"items": {
"type": "string",
"enum": [
"system",
"user",
"assistant",
"tool"
]
},
"description": "Roles whose messages are protected."
},
"duplicate_threshold": {
"type": "number",
"minimum": 0.5,
"maximum": 1,
"default": 0.9,
"description": "Word-overlap ratio from which a later message of the same role counts as a near-duplicate of an earlier one."
},
"max_message_chars": {
"type": "integer",
"minimum": 80,
"maximum": 4000,
"default": 400,
"description": "Length to which unprotected survivors are trimmed in the trim stage."
}
}
}Veröffentlichtes Eingabebeispiel
{
"messages": [
{
"role": "system",
"content": "You are a logistics dispatcher. Always answer with the shipment id first."
},
{
"role": "user",
"content": "Where is shipment DE-4471? It left Hamburg on Monday morning and should reach Lyon by Thursday."
},
{
"role": "assistant",
"content": "DE-4471 is in transit and cleared the Strasbourg hub at 03:10. Estimated arrival in Lyon is Thursday 14:00."
},
{
"role": "user",
"content": "Where is shipment DE-4471? It left Hamburg on Monday morning and should reach Lyon by Thursday."
},
{
"role": "assistant",
"content": "DE-4471 is still on schedule, no new scan since Strasbourg."
},
{
"role": "user",
"content": "Good. Book the return leg for Friday."
}
],
"budget_chars": 400,
"keep_last_n": 2,
"keep_roles": [
"system"
],
"duplicate_threshold": 0.9,
"max_message_chars": 120
}Ergebnis & Dokumentation
Veröffentlichtes Ergebnisschema anzeigen
{
"$ref": "https://agent.halowerk.com/v1/memory-compact/schema#/outputSchema"
}Veröffentlichtes Ergebnisbeispiel öffnen
Maschinenlesbare Dokumentation dieses Hubs
Quelle dieser Seite: der veröffentlichte HALOWERK-Katalog. Stand: 2026-11-01, 15:19 UTC.
Weitere Endpunkte dieses Hubs
- Agentenwerk0,002 USDC
a2a card validate
POSThttps://agent.halowerk.com/v1/a2a-card-validateValidates an Agent Card document against the A2A convention and returns findings by severity: error (the card is unusable as published), warning (works, but a consuming agent will guess), info (recommended field absent).
- Agentenwerk0,003 USDC
artifact receipt
POSThttps://agent.halowerk.com/v1/artifact-receiptSeal binds an exact UTF-8 content SHA-256 digest and expiry to a HALOWERK Ed25519 signature; verify checks signature, expiry and optional exact content. The service public key is included. This attests digest receipt only, not truth, legal
- Agentenwerk0,001 USDC
base64 codec
POSThttps://agent.halowerk.com/v1/base64-codecConverts text to padded standard Base64 or decodes canonical Base64 to valid UTF-8. Rejects noncanonical padding, whitespace, URL-safe alphabet and invalid decoded UTF-8.