SDK Migration Guide
This guide helps migrate older Papr integrations to current API patterns.
Key Migrations
Graph Configuration
- Old:
graph_generation - New:
memory_policy
Use memory_policy for graph mode, constraints, and governance controls.
User Identity
- Old:
user_id - New:
external_user_id
Use your application user ID as external_user_id.
Search Ranking Flag
- Old:
rank_results - New: use retrieval tuning + agentic graph defaults
Prefer:
enable_agentic_graph=true- tuned memory/node limits
Legacy Document Schema Flags
- Old:
simple_schema_modeandproperty_overridesstyle flows - New: use
memory_policy+ schema defaults + constraints
Migration Checklist
- Replace deprecated request fields.
- Add tenant scope fields where applicable.
- Add policy defaults in one shared helper.
- Re-run integration tests for retrieval and access control.
Example Update (Python)
# Before
client.memory.add(
content="...",
user_id="u_1",
graph_generation={"mode": "auto"}
)
# After
client.memory.add(
content="...",
external_user_id="u_1",
memory_policy={"mode": "auto"}
)