Skip to content

Commit a01b9f7

Browse files
increase zoom sensitivity, move modify to o3
1 parent 2dcc939 commit a01b9f7

File tree

3 files changed

+17
-4
lines changed

3 files changed

+17
-4
lines changed

backend/app/routers/modify.py

+15-2
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,17 @@
55
from anthropic._exceptions import RateLimitError
66
from app.prompts import SYSTEM_MODIFY_PROMPT
77
from pydantic import BaseModel
8+
from backend.app.services.o3_mini_openrouter_service import OpenRouterO3Service
9+
810

911
load_dotenv()
1012

1113
router = APIRouter(prefix="/modify", tags=["Claude"])
1214

1315
# Initialize services
14-
claude_service = ClaudeService()
16+
# claude_service = ClaudeService()
17+
o3_service = OpenRouterO3Service()
18+
1519

1620
# Define the request body model
1721

@@ -45,7 +49,16 @@ async def modify(request: Request, body: ModifyRequest):
4549
]:
4650
return {"error": "Example repos cannot be modified"}
4751

48-
modified_mermaid_code = claude_service.call_claude_api(
52+
# modified_mermaid_code = claude_service.call_claude_api(
53+
# system_prompt=SYSTEM_MODIFY_PROMPT,
54+
# data={
55+
# "instructions": body.instructions,
56+
# "explanation": body.explanation,
57+
# "diagram": body.current_diagram,
58+
# },
59+
# )
60+
61+
modified_mermaid_code = o3_service.call_o3_api(
4962
system_prompt=SYSTEM_MODIFY_PROMPT,
5063
data={
5164
"instructions": body.instructions,

src/components/header.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ export function Header() {
4242
</span>
4343
</span>
4444
</Link>
45-
<nav className="flex items-center gap-2 sm:gap-6">
45+
<nav className="flex items-center gap-5 sm:gap-6">
4646
{/* <Link
4747
href="https://api.gitdiagram.com"
4848
className="text-sm font-medium text-black transition-transform hover:translate-y-[-2px] hover:text-purple-600"

src/components/mermaid-diagram.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ const MermaidChart = ({ chart, zoomingEnabled = true }: MermaidChartProps) => {
5555
center: true,
5656
minZoom: 0.1,
5757
maxZoom: 10,
58-
zoomScaleSensitivity: 0.1,
58+
zoomScaleSensitivity: 0.3,
5959
});
6060
}
6161
}

0 commit comments

Comments
 (0)