Skip to content

[Feature]: Native MakerSuite RPC specs for ImprovePrompt, GeminiSpeechToText, createInteractionBidiStream, and GetModelQuota #366

Not planned

Description

@lawrancehoy-cyber

想要什么,用来做什么 / What you want and what for

想要什么,用来做什么 / What you want and what for

Exact wire schemas and WAA proof bindings extracted from current AI Studio web bundles (YUh4Se.js / m_b.js) for five MakerSuite RPCs/transports not yet wired in v0.3.17:

  1. MakerSuiteService/ImprovePrompt (native backend for POST /v1beta/voices:improvePrompt)

    • Currently internal/api/voices_extra.go (handleVoiceImprove) emulates voice prompt rewriting via a GenerateContent prompt (voiceImproveInstruction).
    • Native RPC: POST /$rpc/google.internal.alkali.applications.makersuite.v1.MakerSuiteService/ImprovePrompt
    • Request (_.ydb):
      • field 1 (index 0): prompt (string)
      • field 2 (index 1): waaProof (string)
      • field 3 (index 2): promptType enum (1 = PROMPT_TYPE_GENERATE_VOICE, 2 = PROMPT_TYPE_INTERACTIVE_VIDEO)
      • fields 4, 5: optional booleans (interactive video)
      • fields 6, 7: optional referenceImage bytes + mimeType
    • WAA proof binding (_.KBh): ${prompt} ${promptTypeEnumName} (e.g. ${prompt} PROMPT_TYPE_GENERATE_VOICE).
    • Response (zdb): field 1 (index 0) is the rewritten prompt string (optional field 2 text, fields 3/4 image bytes + mimeType for interactive video).
  2. MakerSuiteService/GeminiSpeechToText (lightweight STT without Drive upload/delete)

    • Currently internal/aistudio/transcription_service.go uploads every audio clip to Google Drive, runs GenerateContent, and deletes the Drive file (3 round-trips).
    • Native RPC: POST /$rpc/google.internal.alkali.applications.makersuite.v1.MakerSuiteService/GeminiSpeechToText
    • Request (_.N8a):
      • field 1 (index 0): Blob ([mimeType, base64Audio])
      • field 2 (index 1): waaProof (string)
    • WAA proof binding (kBf): ${mimeType} ${base64Audio} (Base64 string via .getData().If(), not byte length).
    • Response (_.O8a): field 1 (index 0) is the transcribed text string.
  3. Interactions-backed Live streaming (/v1/createInteractionBidiStream)

    • AI Studio's Live client (wNc) opens POST https://webchannel-alkalimakersuite-pa.clients6.google.com/v1/createInteractionBidiStream with useFetchStreams: true for Interactions-backed Live sessions:
    • Setup frame (_.mL outer):
      • field 1 (index 0): setup (iNc: [model, systemInstruction, voiceName, tools, thinkingLevel])
      • field 4 (index 3): waaProof — binding (FMc): [model, systemInstruction, voiceName].filter(Boolean).join(" ")
    • Subsequent client frames (_.mL oneof [1,2,3,5,6,7]):
      • field 2 (index 1): media Blob ([mimeType, base64])
      • field 3 (index 2): text string
      • field 5 (index 4): FunctionResponse
    • Server frames (nNc oneof [1,2,3,4,5,6,7]):
      • field 1: setup complete
      • field 2: media Blob (model audio)
      • field 3: transcription (lNc: [text, finishedBool, kindEnum (1=input, 2=output), durationMs])
      • field 4: thought text (thought: true)
      • field 5: status/turn complete (kNc: [rpcStatus], code 0 => turnComplete + generationComplete)
      • field 6: FunctionCall
  4. Account quota & verification introspection (GetModelQuota, ListModelRateLimits, GetUserVerificationStatus)

    • MakerSuiteService/GetModelQuota: request [model] (_.bcb), response field 1 repeated [metricName, limit, remaining] (Cee, e.g. successful_video_generations).
    • MakerSuiteService/ListModelRateLimits: request [projectName] (_.Xfb).
    • MakerSuiteService/GetUserVerificationStatus: request [] (_.ddb), response field 1 enum status (edb.yb()).
    • Useful for surfacing real per-model remaining quota in the pool quota panel and proactively detecting accounts requiring verification (verify-account).
  5. MakerSuiteService/GenerateFunctionCallAnswer (native backend for Live Playground auto-tool-response)

    • Currently web/src/playground/media/live.ts:550 emulates automatic function-call responses with a GenerateContent JSON call.
    • Native RPC: POST /$rpc/google.internal.alkali.applications.makersuite.v1.MakerSuiteService/GenerateFunctionCallAnswer
    • Request (_.n9a): field 1 FunctionDeclaration (_.xn), field 2 FunctionCall (_.ov), field 3 waaProof — binding (Zoi): [decl.name, decl.description, call.name].join(" ").

版本 / Version

v0.3.17 (5deae85)

Activity

  1. github-actions commented on Dec 3, 2026

    @github-actions

    每人最多同时打开 3 个 Issue,这个 Issue 已自动关闭。请等已有的 Issue 处理完再提,或把内容补充到已有的 Issue 里。

    Each user can have at most 3 open issues at a time, so this one was closed automatically. Please wait until your existing issues are resolved, or add this to one of them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions