Refactor context configuration and settings handling
- Updated context configuration loading path from ~/.claude/settings.json to ~/.claude-mem/settings.json. - Modified the extractPriorMessages function to focus on retrieving the last assistant message only, removing user message extraction. - Enhanced output formatting for displaying prior assistant messages in the context hook. - Added new settings related to token economics and observation filtering in the useSettings hook.
This commit is contained in:
@@ -889,7 +889,7 @@ export class WorkerService {
|
||||
*/
|
||||
private handleGetSettings(req: Request, res: Response): void {
|
||||
try {
|
||||
const settingsPath = path.join(homedir(), '.claude', 'settings.json');
|
||||
const settingsPath = path.join(homedir(), '.claude-mem', 'settings.json');
|
||||
|
||||
if (!existsSync(settingsPath)) {
|
||||
// Return defaults if file doesn't exist
|
||||
@@ -986,7 +986,7 @@ export class WorkerService {
|
||||
}
|
||||
|
||||
// Read existing settings
|
||||
const settingsPath = path.join(homedir(), '.claude', 'settings.json');
|
||||
const settingsPath = path.join(homedir(), '.claude-mem', 'settings.json');
|
||||
let settings: any = { env: {} };
|
||||
|
||||
if (existsSync(settingsPath)) {
|
||||
|
||||
Reference in New Issue
Block a user