Background
LoongSuite currently instruments Mem0 with legacy custom gen_ai.memory.* fields and a broad method-to-operation mapping. The current semantic-convention alignment adds a minimal compatibility adapter, but it intentionally does not claim complete Mem0 support.
OpenTelemetry GenAI semantic conventions now define Memory operations and attributes, including:
- operations:
create_memory_store, search_memory, create_memory, update_memory, upsert_memory, delete_memory, delete_memory_store
gen_ai.memory.store.id
gen_ai.memory.record.id
gen_ai.memory.record.count
- opt-in
gen_ai.memory.query.text
- opt-in
gen_ai.memory.records
Current minimal adapter
add -> upsert_memory
update / batch_update -> update_memory
search / get / get_all / history -> search_memory
delete / batch_delete / delete_all -> delete_memory
- local
Memory / AsyncMemory operations use INTERNAL; remote MemoryClient / AsyncMemoryClient operations use CLIENT
- only explicit store and record identifiers are mapped
- query and record content are emitted only when content capture is enabled
This mapping is intentionally conservative. In particular, delete_all does not necessarily mean delete_memory_store, and framework-scoped user_id / agent_id / run_id values are not assumed to be OpenTelemetry memory-store identifiers.
Required full redesign
Acceptance criteria
- No legacy LoongSuite-only Memory attributes are emitted by default.
- Every supported Mem0 API has a documented operation name, span kind, store-id rule, record normalization rule, and content-capture behavior.
- Unsupported or ambiguous APIs omit fields instead of fabricating identifiers or operation semantics.
- Focused tests and real emitted-span Weaver samples cover local/hosted, sync/async, success/error, and content-capture on/off paths.
- LoongSuite and Robin preserve the same trace semantic contract; commercial metrics remain owned by Robin and are not duplicated by the open-source adapter.
Background
LoongSuite currently instruments Mem0 with legacy custom
gen_ai.memory.*fields and a broad method-to-operation mapping. The current semantic-convention alignment adds a minimal compatibility adapter, but it intentionally does not claim complete Mem0 support.OpenTelemetry GenAI semantic conventions now define Memory operations and attributes, including:
create_memory_store,search_memory,create_memory,update_memory,upsert_memory,delete_memory,delete_memory_storegen_ai.memory.store.idgen_ai.memory.record.idgen_ai.memory.record.countgen_ai.memory.query.textgen_ai.memory.recordsCurrent minimal adapter
add->upsert_memoryupdate/batch_update->update_memorysearch/get/get_all/history->search_memorydelete/batch_delete/delete_all->delete_memoryMemory/AsyncMemoryoperations useINTERNAL; remoteMemoryClient/AsyncMemoryClientoperations useCLIENTThis mapping is intentionally conservative. In particular,
delete_alldoes not necessarily meandelete_memory_store, and framework-scopeduser_id/agent_id/run_idvalues are not assumed to be OpenTelemetry memory-store identifiers.Required full redesign
options=/ nested request objects without relying only on top-level keyword arguments.gen_ai.memory.store.idderivation rules for local and hosted Mem0. Do not repurpose user/session/agent identifiers without an explicit contract.contentrequired;id,metadata, andscorewhen available).delete_all.INTERNALvsCLIENTspan kind for every supported class and deployment mode.loongsuite-semantic-conventionswith the upstream Memory fields and operation enums.Acceptance criteria