Procházet zdrojové kódy

Moving readme to docs

Jay V před 9 měsíci
rodič
revize
4526b14b17

+ 21 - 0
www/src/content/docs/docs/cli.mdx

@@ -1,3 +1,24 @@
 ---
 ---
 title: CLI
 title: CLI
 ---
 ---
+
+## Usage
+
+```bash
+# Start OpenCode
+opencode
+
+# Start with debug logging
+opencode -d
+
+# Start with a specific working directory
+opencode -c /path/to/project
+```
+
+## Command-line Flags
+
+| Flag      | Short | Description                   |
+| --------- | ----- | ----------------------------- |
+| `--help`  | `-h`  | Display help information      |
+| `--debug` | `-d`  | Enable debug mode             |
+| `--cwd`   | `-c`  | Set current working directory |

+ 83 - 0
www/src/content/docs/docs/models.mdx

@@ -2,4 +2,87 @@
 title: Models
 title: Models
 ---
 ---
 
 
+## Supported AI Models
 
 
+OpenCode supports a variety of AI models from different providers:
+
+### OpenAI
+
+- GPT-4.1 family (gpt-4.1, gpt-4.1-mini, gpt-4.1-nano)
+- GPT-4.5 Preview
+- GPT-4o family (gpt-4o, gpt-4o-mini)
+- O1 family (o1, o1-pro, o1-mini)
+- O3 family (o3, o3-mini)
+- O4 Mini
+
+### Anthropic
+
+- Claude 3.5 Sonnet
+- Claude 3.5 Haiku
+- Claude 3.7 Sonnet
+- Claude 3 Haiku
+- Claude 3 Opus
+
+### Google
+
+- Gemini 2.5
+- Gemini 2.5 Flash
+- Gemini 2.0 Flash
+- Gemini 2.0 Flash Lite
+
+### AWS Bedrock
+
+- Claude 3.7 Sonnet
+
+### Groq
+
+- Llama 4 Maverick (17b-128e-instruct)
+- Llama 4 Scout (17b-16e-instruct)
+- QWEN QWQ-32b
+- Deepseek R1 distill Llama 70b
+- Llama 3.3 70b Versatile
+
+### Azure OpenAI
+
+- GPT-4.1 family (gpt-4.1, gpt-4.1-mini, gpt-4.1-nano)
+- GPT-4.5 Preview
+- GPT-4o family (gpt-4o, gpt-4o-mini)
+- O1 family (o1, o1-mini)
+- O3 family (o3, o3-mini)
+- O4 Mini
+
+### Google Cloud VertexAI
+
+- Gemini 2.5
+- Gemini 2.5 Flash
+
+## Using Bedrock Models
+
+To use bedrock models with OpenCode you need three things.
+
+1. Valid AWS credentials (the env vars: `AWS_SECRET_KEY_ID`, `AWS_SECRET_ACCESS_KEY` and `AWS_REGION`)
+2. Access to the corresponding model in AWS Bedrock in your region.
+    a. You can request access in the AWS console on the Bedrock -> "Model access" page.
+3. A correct configuration file. You don't need the `providers` key. Instead you have to prefix your models per agent with `bedrock.` and then a valid model. For now only Claude 3.7 is supported.
+
+```json
+{
+  "agents": {
+    "primary": {
+      "model": "bedrock.claude-3.7-sonnet",
+      "maxTokens": 5000,
+      "reasoningEffort": ""
+    },
+    "task": {
+      "model": "bedrock.claude-3.7-sonnet",
+      "maxTokens": 5000,
+      "reasoningEffort": ""
+    },
+    "title": {
+      "model": "bedrock.claude-3.7-sonnet",
+      "maxTokens": 80,
+      "reasoningEffort": ""
+    }
+  },
+}
+```