datarobot_genai.dragent.plugins.datarobot_mem0_memory
datarobot_mem0_memory
NAT memory provider backed by DataRobot's Mem0 client.
This provider wires datarobot-genai[dragent] into NAT's MemoryEditor
interface so auto_memory_agent can store and retrieve long-term memory.
Backend selection is driven by config:
agent_memory_space_id→ the DataRobot Memory Service's mem0-compatible API, reached at{DATAROBOT_ENDPOINT}/memory/{agent_memory_space_id}/and authenticated with the DataRobot API token. See PBMP-7431 ("Agentic Memory Service"), section "Connect to DataRobot memory" / "API Layout".api_key(orMEM0_API_KEY) → Mem0's hosted SaaS athttps://api.mem0.ai. Used when noagent_memory_space_idis configured.
Both routes share the same MemoryEditor adapter because the DR endpoint
is API-compatible with mem0 — only the host and auth token differ.
When neither route is configured (no agent_memory_space_id + token and no
api_key / MEM0_API_KEY), the provider yields an
:class:UnconfiguredMemoryEditor so workflows can declare dr_mem0_memory
unconditionally and enable memory later via runtime parameters or env vars.
Config
Bases: DataRobotAppFrameworkBaseSettings
Finds variables in the priority order of: env variables (including Runtime Parameters), .env, file_secrets, then Pulumi output variables.
Source code in datarobot_genai/dragent/plugins/datarobot_mem0_memory.py
DRMem0MemoryClientConfig
Bases: MemoryBaseConfig, RetryMixin
A NAT memory backend backed by datarobot-genai's Mem0 client.
Backend selection:
- If
agent_memory_space_idis set, requests go to the DataRobot Memory Service's mem0-compatible endpoint at{datarobot_endpoint}/memory/{agent_memory_space_id}/authenticated withdatarobot_api_token(orDATAROBOT_API_TOKEN). - Otherwise,
api_key(orMEM0_API_KEY) is used against Mem0's hosted SaaS (hostdefaults tohttps://api.mem0.ai).
Source code in datarobot_genai/dragent/plugins/datarobot_mem0_memory.py
UnconfiguredMemoryEditor
Bases: MemoryEditor
No-op memory backend returned when dr_mem0_memory has no credentials.
Source code in datarobot_genai/dragent/plugins/datarobot_mem0_memory.py
DRMem0Editor
Bases: MemoryEditor
Adapt Mem0Client to NAT's MemoryEditor interface.
Source code in datarobot_genai/dragent/plugins/datarobot_mem0_memory.py
216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 | |
is_memory_editor_configured
Return False when dr_mem0_memory yielded an unconfigured no-op editor.