Agent Shared Context
Agent Shared Context is an experimental feature and is under active development.
The AI Assistant's shared context feature allows team members to share workflow history and context on a shared filesystem. This page covers the administrator's role in setting up and maintaining the shared directory.
Overview
When shared context is enabled, each user's AI Assistant writes a summary of workflow operations to the shared directory. Other team members' assistants read these memories during sync, importing new entries into their local memory for search.
The shared directory only contains summaries of workflow metadata (application names, settings, project IDs). It does not contain simulation data, input files, or result files.
Setting Up the Shared Directory
Recommended Path
Choose a location on a shared filesystem that all HPC users can access:
/shared/hpcbox/agent-context/
Or a project-specific location:
/projects/team-alpha/hpcbox-context/
Creating the Directory
# Create the directory
mkdir -p /shared/hpcbox/agent-context/
# Set permissions: owner=rwx, group=rwx, others=none
chmod 770 /shared/hpcbox/agent-context/
# Set the group to your HPC users group
chgrp hpcusers /shared/hpcbox/agent-context/
# Set the setgid bit so new files inherit the group
chmod g+s /shared/hpcbox/agent-context/
The setgid bit ensures that memories created by individual users inherit the group ownership, making them readable by all team members.
File Permissions
Each user creates their own memory files. The recommended umask for HPC users is 0027 or 0007 so that group members can read each other's files:
Users only write to their own file. All other files are read-only from each user's perspective.
Monthly Rotation
The assistant automatically rotates shared memory context files at the start of each month:
- The previous month's file is compressed with gzip
- A new context memory file is started for the current month
- Archived files are kept in the same directory but are not included in sync operations
Manual Cleanup
Over time, archived files accumulate. You can safely delete old archives:
# Remove archives older than 6 months
find /shared/hpcbox/agent-context/ -name "*.gz" -mtime +180 -delete
Monitoring
Check Directory Size
du -sh /shared/hpcbox/agent-context/
User Setup
Once the directory is created, inform your users of the path. They enable shared context in the AI Assistant panel:
- Toggle Share Context on
- Set the Shared directory to the path you created
- Click Reconnect
See the User Guide for detailed instructions.
Security Considerations
- Shared context files contain workflow metadata summaries (application names, option values, project IDs, file paths). Evaluate whether this information is acceptable to share within your team.
- Use filesystem permissions (group ownership, setgid) to restrict access to authorized users.
- The assistant does not share simulation data, input files, result files, or API keys through the shared context mechanism.
- Each user's local SQLite database (
~/.drizti/hpcbox/agent/context.db) remains private and is not shared.