# Yntra Code installer — Windows (PowerShell). irm https://yntra.ai/install.ps1 | iex $ErrorActionPreference = "Stop" $Base = if ($env:YNTRA_DOWNLOAD) { $env:YNTRA_DOWNLOAD } else { "https://yntra.ai/download" } $Api = if ($env:YNTRA_API) { $env:YNTRA_API } else { "https://api.yntra.ai/v1" } $arch = if ([Environment]::Is64BitOperatingSystem -and $env:PROCESSOR_ARCHITECTURE -eq "ARM64") { "arm64" } else { "x64" } $plat = "windows-$arch"; $dir = "$env:LOCALAPPDATA\Yntra\bin"; $cfg = "$env:APPDATA\yntra" New-Item -ItemType Directory -Force -Path $dir, $cfg | Out-Null Write-Host "◆ YNTRA CODE installing for $plat…" -ForegroundColor Green $tmp = Join-Path $env:TEMP "yntra.exe" Invoke-WebRequest "$Base/$plat/yntra.exe" -OutFile $tmp -UseBasicParsing $sums = (Invoke-WebRequest "$Base/SHA256SUMS" -UseBasicParsing).Content $want = ($sums -split "`n" | Where-Object { $_ -match " \./$plat/yntra\.exe$" }) -replace " .*", "" $got = (Get-FileHash $tmp -Algorithm SHA256).Hash.ToLower() if (-not $want -or $want.Trim() -ne $got) { throw "Checksum mismatch: download aborted." } Move-Item -Force $tmp "$dir\yntra-bin.exe" # Yntra Code remoto: plugin that lets you follow / continue this session from yntra.ai (outbound connection only) $ptmp = Join-Path $env:TEMP "yntra-remote.js" Invoke-WebRequest "$Base/yntra-remote.js" -OutFile $ptmp -UseBasicParsing $pwant = ($sums -split "`n" | Where-Object { $_ -match " \./yntra-remote\.js$" }) -replace " .*", "" if (-not $pwant -or $pwant.Trim() -ne (Get-FileHash $ptmp -Algorithm SHA256).Hash.ToLower()) { throw "Checksum mismatch (remote plugin): download aborted." } Move-Item -Force $ptmp "$cfg\yntra-remote.js" $pluginUrl = "file:///" + ("$cfg\yntra-remote.js" -replace "\\", "/") @" { "theme": "yntra", "share": "disabled", "autoupdate": false, "enabled_providers": ["yntra"], "provider": { "yntra": { "npm": "@ai-sdk/openai-compatible", "name": "Yntra", "options": { "baseURL": "$Api", "apiKey": "{env:YNTRA_API_KEY}" }, "models": { "yntra": { "name": "Yntra", "tool_call": true } } } }, "model": "yntra/yntra", "small_model": "yntra/yntra", "permission": { "edit": "allow", "webfetch": "allow", "websearch": "allow", "bash": { "*": "allow", "sudo*": "ask", "rm -rf*": "ask", "git push*": "ask", "git reset --hard*": "ask", "dd*": "ask", "shutdown*": "ask", "reboot*": "ask" } }, "instructions": ["$env:APPDATA\\yntra\\AGENTS.md"], "plugin": ["$pluginUrl"] } "@ | Set-Content -Encoding UTF8 "$cfg\yntra.json" @' @echo off if "%1"=="login" ( powershell -NoProfile -Command "$k = Read-Host 'Paste your Yntra API key' -AsSecureString; [IO.File]::WriteAllText(\"$env:APPDATA\yntra\key\", [Runtime.InteropServices.Marshal]::PtrToStringAuto([Runtime.InteropServices.Marshal]::SecureStringToBSTR($k)))" echo Saved. Run: yntra exit /b 0 ) if "%1"=="remote" ( if "%2"=="on" ( type nul > "%APPDATA%\yntra\remote-on" & echo Yntra Code remoto ATTIVO: segui la sessione da yntra.ai - Yntra Code remoto & exit /b 0 ) if "%2"=="off" ( del /q "%APPDATA%\yntra\remote-on" 2>nul & echo Yntra Code remoto disattivato & exit /b 0 ) if exist "%APPDATA%\yntra\remote-on" ( echo Yntra Code remoto: attivo ) else ( echo Yntra Code remoto: spento - attiva con: yntra remote on ) exit /b 0 ) if not exist "%APPDATA%\yntra\key" ( echo First run: yntra login & exit /b 1 ) set /p YNTRA_API_KEY=<"%APPDATA%\yntra\key" set OPENCODE_CONFIG=%APPDATA%\yntra\yntra.json "%LOCALAPPDATA%\Yntra\bin\yntra-bin.exe" %* '@ | Set-Content -Encoding ASCII "$dir\yntra.cmd" @" # Yntra Code — the agent You are Yntra Code, a senior AI software engineer on the user's own computer (not a sandbox). You have a real shell, the filesystem and internet access. Work autonomously: read the project, plan, then create/edit files and run commands. Install what the task needs, run builds and tests, use git, fetch docs and search the web; do not ask for ordinary safe commands. Run tests and report the real result. Project memory: keep a file ``.yntra/MEMORY.md`` in the project. Read it at the start of a task and update it with the stack, how to build/run/test, the file layout, conventions, decisions and a "what I did last" log. On a big codebase, map it with grep/glob/read and open only the files a step needs; rely on the memory file to not lose the thread across many files and sessions. Safety (financial / production code): never work on production or live servers — use a copy or a git branch and show diffs for review. Never read, print or commit secrets (.env, keys, tokens, real card/account numbers). Ask before destructive actions (rm -rf, git reset --hard / force push, dropping a database, sudo). Security work only on the project's own code or authorised targets. Answer in the user's language; code and commits in English. "@ | Set-Content -Encoding UTF8 "$cfg\AGENTS.md" $p = [Environment]::GetEnvironmentVariable("Path", "User") if ($p -notlike "*$dir*") { [Environment]::SetEnvironmentVariable("Path", "$p;$dir", "User") } Write-Host "✔ Installed. Open a new terminal, then: yntra login → yntra" -ForegroundColor Green