index.ts 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /** Host BFF entry and Loader shell for the Remote contribution assembly. */
  2. import type { TypeRTForwardableEvent } from '@deepseek-ai/dsh-type-meta'
  3. import { API_REMOTE_FORWARDED_EVENTS } from './remote-events.ts'
  4. // The owner packages' client-safe `./types` exports carry the cordis `Events`
  5. // declarations for every allowlisted event. Pulling them into this face is what
  6. // makes the shape assertion below judge real signatures rather than an empty
  7. // event vocabulary.
  8. import type {} from '@deepseek-ai/dsh-commands/types'
  9. import type {} from '@deepseek-ai/dsh-credentials/types'
  10. import type {} from '@deepseek-ai/dsh-llm/types'
  11. import type {} from '@deepseek-ai/dsh-agent-presets/types'
  12. import type {} from '@deepseek-ai/dsh-settings/types'
  13. export {
  14. ApiRemoteSessionNotFound,
  15. ApiRemoteSubagentSessionOwnership,
  16. apiRemoteSubagentOwnershipError,
  17. createApiRemoteAgentResolver,
  18. hasApiRemoteSubagentOwner,
  19. inspectApiRemoteSession,
  20. } from './agent-lookup.ts'
  21. export type {
  22. ApiRemoteAgentOptions,
  23. ApiRemoteAgentResult,
  24. ApiRemoteLookupError,
  25. } from './agent-lookup.ts'
  26. export { API_REMOTE_FORWARDED_EVENTS } from './remote-events.ts'
  27. export type { ApiRemoteForwardedEvent } from './types.ts'
  28. // Shape gate over the allowlist, kept in the Host face because the Host's event
  29. // vocabulary is the authoritative one. It pins three things at compile time:
  30. // every entry NAMES a declared event (the predicate is keyed on `keyof
  31. // Events`), no entry BINDS a Scope (a scoped event's `ThisParameterType` is not
  32. // `unknown`, which is how "must not depend on AgentScope" is stated statically),
  33. // and every entry is ONE-WAY (a waterfall or bail shape returns something other
  34. // than void and is excluded). Widening the array to an event that fails any of
  35. // these fails here, not on the wire.
  36. API_REMOTE_FORWARDED_EVENTS satisfies readonly TypeRTForwardableEvent[]
  37. /** Host plugin body; the selected contributions mount only in Client environments. */
  38. export function apply(): void {}