egoist / egoist/shell-ask

[FR] Allow config global custom instruction

Open
#27 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
443
Forks
21
PR merge metrics
No merged PRs in 30d

Description

## Problem Description
Currently, users need to repeatedly specify custom instructions (e.g., response rules, tone, style, and language requirements) for different conversation sessions. This redundancy makes it inefficient to maintain consistent interaction patterns across multiple conversations.

## Proposed Solution
Introduce a `custom_instruction` (like the feature in ChatGPT website) configuration parameter that allows users to define global preset rules in configuration files. This would enable:
```json
{
"default_model": "gpt-4o",
"openai_api_key": "sk-xxxxxxxxxxxxxx",
"custom_instruction": "Remember your name is Jarvis, and I am your master named Kortin. Respond in Simplified Chinese ONLY. Maintain formal tone and avoid emojis.",
}
```
When ask to LLM, the messages will be:
```javascript
[
{
role: 'system',
content: 'Remember your name is Jarvis, and I am your master named Kortin. Respond in Simplified Chinese ONLY. Maintain formal tone and avoid emojis.\nContext:\nplatform: darwin\nshell: /bin/zsh'
},
{ role: 'user', content: 'Introduce yourself.' }
]
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.