Skip to content

Conversation

@cdbartholomew
Copy link
Contributor

Summary

  • Enable the operation validator extension to be loaded from environment configuration
  • Pass the loaded extension to MemoryEngine, allowing pre/post operation hooks
  • Supports usage metering, rate limiting, and audit logging via the extension system

Test plan

  • Verify server starts without operation validator configured (default behavior)
  • Verify server loads operation validator when HINDSIGHT_API_OPERATION_VALIDATOR_EXTENSION is set
  • Confirm extension hooks are called for retain/recall/reflect operations

Enable the operation validator extension to be loaded from environment
configuration and passed to MemoryEngine, allowing pre/post operation
hooks for usage metering, rate limiting, and audit logging.

# Create MemoryEngine (reads configuration from environment)
_memory = MemoryEngine()
_memory = MemoryEngine(operation_validator=operation_validator)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you do the same for tenant_extension ?

@nicoloboschi nicoloboschi merged commit dfa7cec into main Dec 23, 2025
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants