Skip to content

Commit 7350e51

Browse files
authored
docs: added amazon nova api model provider (strands-agents#347)
1 parent 06bd841 commit 7350e51

File tree

4 files changed

+84
-1
lines changed

4 files changed

+84
-1
lines changed
Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# Amazon Nova
2+
3+
[Amazon Nova](https://nova.amazon.com/) is a new generation of foundation models with frontier intelligence and industry leading price performance. Generate text, code, and images with natural language prompts. The [`strands-amazon-nova`](https://pypi.org/project/strands-amazon-nova/) package ([GitHub](https://github.com/amazon-nova-api/strands-nova)) provides an integration for the Strands Agents SDK, enabling seamless use of Amazon Nova models.
4+
5+
## Installation
6+
7+
Amazon Nova integration is available as a separate package:
8+
9+
```bash
10+
pip install strands-agents strands-amazon-nova
11+
```
12+
13+
## Usage
14+
15+
After installing `strands-amazon-nova`, you can import and initialize the Amazon Nova API provider:
16+
17+
```python
18+
from strands import Agent
19+
from amazon_nova import NovaAPIModel
20+
21+
model = NovaAPIModel(
22+
api_key=os.env(NOVA_API_KEY"), # or set NOVA_API_KEY env var
23+
model_id="nova-2-lite-v1",
24+
params={
25+
"max_tokens": 1000,
26+
"temperature": 0.7,
27+
}
28+
)
29+
30+
agent = Agent(model=model)
31+
response = await agent.invoke_async("Can you write a short story?")
32+
print(response.message)
33+
```
34+
35+
## Configuration
36+
37+
### Environment Variables
38+
39+
```bash
40+
export NOVA_API_KEY="your-api-key"
41+
```
42+
43+
### Model Configuration
44+
45+
```python
46+
from amazon_nova import NovaAPIModel
47+
48+
model = NovaAPIModel(
49+
api_key=os.env(NOVA_API_KEY"), # Required: Nova API key
50+
model_id="nova-2-lite-v1", # Required: Model ID
51+
base_url="https://api.nova.amazon.com/v1", # Optional, default shown
52+
timeout=300.0, # Optional, request timeout in seconds
53+
params={ # Optional: Model parameters
54+
"max_tokens": 4096, # Maximum tokens to generate
55+
"max_completion_tokens": 4096, # Alternative to max_tokens
56+
"temperature": 0.7, # Sampling temperature (0.0-1.0)
57+
"top_p": 0.9, # Nucleus sampling (0.0-1.0)
58+
"reasoning_effort": "medium", # For reasoning models: "low", "medium", "high"
59+
"system_tools": ["nova_grounding", "nova_code_interpreter"] # Available system tools from Nova API
60+
"metadata": {}, # Additional metadata
61+
}
62+
)
63+
```
64+
65+
**Supported Parameters in `params`:**
66+
- `max_tokens` (int): Maximum tokens to generate (deprecated, use max_completion_tokens)
67+
- `max_completion_tokens` (int): Maximum tokens to generate
68+
- `temperature` (float): Controls randomness (0.0 = deterministic, 1.0 = maximum randomness)
69+
- `top_p` (float): Nucleus sampling threshold
70+
- `reasoning_effort` (str): For reasoning models - "low", "medium", or "high"
71+
- `system_tools` (list): Available system tools from the Nova API - currently `nova_grounding` and `nova_code_interpreter`
72+
- `metadata` (dict): Additional request metadata
73+
74+
## References
75+
76+
- [strands-amazon-nova GitHub Repository](https://github.com/amazon-nova-api/strands-nova)
77+
- [Amazon Nova](https://nova.amazon.com/)
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
2+
<auto-redirect />
3+
4+
This guide has moved to [community/model-providers/amazon-nova](../../../community/model-providers/amazon-nova.md).

docs/user-guide/quickstart.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -442,6 +442,7 @@ Strands Agents supports several other model providers beyond Amazon Bedrock:
442442
- **[Ollama](concepts/model-providers/ollama.md)** - Run models locally for privacy or offline use
443443
- **[OpenAI](concepts/model-providers/openai.md)** - Access to OpenAI or OpenAI-compatible models
444444
- **[Writer](concepts/model-providers/writer.md)** - Access to Palmyra models
445+
- **[Amazon Nova <sup> community</sup>](../community/model-providers/amazon-nova.md)** - API access to Amazon Nova models
445446
- **[Cohere <sup> community</sup>](../community/model-providers/cohere.md)** - Use Cohere models through an OpenAI compatible interface
446447
- **[CLOVA Studio<sup> community</sup>](../community/model-providers/clova-studio.md)** - Korean-optimized AI models from Naver Cloud Platform
447448
- **[FireworksAI<sup> community</sup>](../community/model-providers/fireworksai.md)** - Use FireworksAI models through an OpenAI compatible interface

mkdocs.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,8 @@ nav:
101101
- SageMaker: user-guide/concepts/model-providers/sagemaker.md
102102
- Writer: user-guide/concepts/model-providers/writer.md
103103
- Custom Providers: user-guide/concepts/model-providers/custom_model_provider.md
104-
- Cohere<sup> community</sup>: user-guide/concepts/model-providers/cohere.md # ALWAYS ADD A SPACE BEFORE COMMUNITY
104+
- Amazon Nova<sup> community</sup>: user-guide/concepts/model-providers/amazon-nova.md # ALWAYS ADD A SPACE BEFORE COMMUNITY
105+
- Cohere<sup> community</sup>: user-guide/concepts/model-providers/cohere.md
105106
- CLOVA Studio<sup> community</sup>: user-guide/concepts/model-providers/clova-studio.md
106107
- FireworksAI<sup> community</sup>: user-guide/concepts/model-providers/fireworksai.md
107108
- Streaming:

0 commit comments

Comments
 (0)