본문으로 건너뛰기
문서 탐색: 의사결정 모델 / 버전

버전

RightNow AI의사결정 모델버전 업데이트

이 페이지의 내용

현재 모델을 따르려면 별칭을, 버전을 고르려면 고정한 ID를 쓰세요.

decide.ts
import { RightNowClient } from '@rightnowai/rightnow';

const client = new RightNowClient({
  apiKey: process.env.RIGHTNOW_API_KEY,
  baseURL: "https://api.rightnowai.co/v1",
});
const reply = await client.decide({
  "model": "rightnow-decision-3.0.0",
  "state": "The blender I ordered arrived with a cracked jar.",
  "questions": {
    "damaged": {
      "type": "boolean",
      "instructions": "Did the item arrive damaged?"
    }
  }
});
console.log(JSON.stringify(reply, null, 2));

// Set RIGHTNOW_API_KEY to your API key before running this example.
// Run this example on your server.
// SDK defaults: The default is 5 retries, also the maximum, with 150 seconds
// per attempt and a 60-second total retry budget. A single wait longer than 60
// seconds raises the last error.
// Use Retry-After-Ms, or Retry-After when milliseconds are absent. The wait is
// never shorter than a random backoff floor: a random fraction of 0.5 seconds
// doubled for each attempt, capped at 8 seconds.

rnsk_로 시작하는 키는 일반 HTTP로 결정 경로를 호출합니다.

SDK 패키지 버전은 0.5.1입니다. 패키지 버전과 모델 ID는 서로 별개입니다.

별칭

rightnow-decision는 검증된 별칭 대상을 따릅니다. 그 대상은 모델 목록의 alias_for에서 확인하세요. 목록은 같은 모델을 이전 ID로 표시합니다. 요청은 두 ID 중 어느 쪽이든 받습니다.

고정한 버전

고정한 ID는 검증된 모델의 특정 버전을 가리킵니다. rightnow-decision는 rightnow-decision-3.0.0으로 답합니다. 이것은 제공 중인 유일한 버전이며 고정할 수도 있습니다.

사용할 수 있는 이름을 확인하려면 인증된 GET /v1/models을 쓰세요. 모델 레퍼런스에 확인 요청이 있습니다.

신뢰도

새 답변에는 decision, confidence, alternatives, calibrated가 들어 있습니다. confidence는 선택된 결과의 확률이고, 이번 릴리스에서 calibrated는 false입니다. 이전의 멱등 재전송은 저장된 답변 형태를 유지하므로, 거기에는 이 신뢰도의 의미를 적용하지 마세요.

제공 종료

고정한 모델 ID는 제공이 끝날 수 있습니다. 그 뒤에는 404 model_not_found를 반환하므로 별칭이나 모델 목록의 버전을 쓰세요. 앱의 고정 버전을 바꾸기 전에 대체 모델을 검토하세요.