Skip to content

Commit

Permalink
Merge pull request #21 from concord-consortium/ai-assistant-settings-…
Browse files Browse the repository at this point in the history
…version-control

feat: assistant settings version control
  • Loading branch information
emcelroy authored Jan 3, 2025
2 parents d56ed82 + c034024 commit c547f4a
Show file tree
Hide file tree
Showing 9 changed files with 11,836 additions and 1 deletion.
24 changes: 24 additions & 0 deletions ai-assistant-settings/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# AI Assistant Settings

This is a repository of AI assistant settings values for which we want simple version control. The settings values are currently entered and saved at platform.openai.com.

## Directory Structure

Each assistant in the DAVAI project has its own subdirectory containing:

- `instructions.txt`: Stores the assistant's Instructions setting value.
- `functions/`: Contains individual text files for each defined function.

## Workflow

Since non-developers can modify settings but are unlikely to update this repository, developers should follow these steps to ensure the repository stays reasonably up-to-date:

1. **Before making changes, sync existing values.** Use the `sync:assistant-settings` npm script to fetch the latest settings from platform.openai.com, then commit any changes.
2. **Update settings.** Make changes on platform.openai.com, then update the corresponding files here and commit.

## Scripts

The `sync:assistant-settings` npm script uses `sync-settings.mts` in the `scripts` directory to fetch and update assistant settings automatically via the OpenAI API.

### Usage:
`npm run sync:assistant-settings`
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "create_request",
"description": "Create a request to send to the CODAP Data Interactive API",
"parameters": {
"type": "object",
"properties": {
"action": {
"type": "string",
"description": "The action to perform"
},
"resource": {
"type": "string",
"description": "The resource to act upon"
},
"values": {
"type": "object",
"description": "The values to pass to the action"
}
},
"additionalProperties": false,
"required": [
"action",
"resource"
]
},
"strict": false
}
3,869 changes: 3,869 additions & 0 deletions ai-assistant-settings/assistants/asst_6YHBiHu9CPzDh2VokFzJyBel/instructions.txt

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "create_request",
"description": "Create a request to send to the CODAP Data Interactive API",
"parameters": {
"type": "object",
"properties": {
"action": {
"type": "string",
"description": "The action to perform"
},
"resource": {
"type": "string",
"description": "The resource to act upon"
},
"values": {
"type": "object",
"description": "The values to pass to the action"
}
},
"additionalProperties": false,
"required": [
"action",
"resource"
]
},
"strict": false
}
3,902 changes: 3,902 additions & 0 deletions ai-assistant-settings/assistants/asst_v9QCHtVvhFqI5lmLjIZnSQUG/instructions.txt

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"name": "create_request",
"description": "Create a request to send to the CODAP Data Interactive API",
"parameters": {
"type": "object",
"properties": {
"action": {
"type": "string",
"description": "The action to perform"
},
"resource": {
"type": "string",
"description": "The resource to act upon"
},
"values": {
"type": "object",
"description": "The values to pass to the action"
}
},
"additionalProperties": false,
"required": [
"action",
"resource"
]
},
"strict": false
}
Loading

0 comments on commit c547f4a

Please sign in to comment.