Spaces:
Running
Running
Download src/lib/state.ts from imspsycho/copilot-api: direct link, hf CLI and curl.
- Browser
- Download file 747 Bytes
-
https://huggingface.co/spaces/imspsycho/copilot-api/resolve/main/src/lib/state.ts
- Command line
-
hf download hf://spaces/imspsycho/copilot-api/src/lib/state.ts
-
curl -L -o state.ts https://huggingface.co/spaces/imspsycho/copilot-api/resolve/main/src/lib/state.ts
747 Bytes
| import { randomUUID } from "node:crypto" | |
| import type { ModelsResponse } from "~/services/copilot/get-models" | |
| export interface State { | |
| githubToken?: string | |
| userName?: string | |
| copilotToken?: string | |
| accountType: string | |
| models?: ModelsResponse | |
| vsCodeVersion?: string | |
| macMachineId?: string | |
| vsCodeSessionId?: string | |
| vsCodeDeviceId: string | |
| manualApprove: boolean | |
| rateLimitWait: boolean | |
| showToken: boolean | |
| // Rate limiting configuration | |
| rateLimitSeconds?: number | |
| lastRequestTimestamp?: number | |
| verbose: boolean | |
| copilotApiUrl?: string | |
| } | |
| export const state: State = { | |
| accountType: "individual", | |
| manualApprove: false, | |
| rateLimitWait: false, | |
| showToken: false, | |
| verbose: false, | |
| vsCodeDeviceId: randomUUID(), | |
| } | |