@promptbook/cli 0.112.0-45 → 0.112.0-47

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/README.md +16 -16
  2. package/esm/index.es.js +884 -285
  3. package/esm/index.es.js.map +1 -1
  4. package/esm/scripts/run-codex-prompts/common/waitForPause.d.ts +13 -1
  5. package/esm/scripts/run-codex-prompts/git/commitChanges.d.ts +3 -1
  6. package/esm/scripts/run-codex-prompts/ui/buildCoderRunOctopusVisual.d.ts +13 -0
  7. package/esm/scripts/run-codex-prompts/ui/buildCoderRunUiFrame.d.ts +3 -1
  8. package/esm/scripts/run-codex-prompts/ui/coderRunUiRefresh.d.ts +23 -0
  9. package/esm/scripts/run-codex-prompts/ui/coderRunUiText.d.ts +36 -0
  10. package/esm/scripts/run-codex-prompts/ui/renderCoderRunUi.d.ts +4 -3
  11. package/esm/scripts/utils/emojiTags/scanEmojiTagUsage.d.ts +51 -0
  12. package/esm/src/avatars/AvatarOrImage.d.ts +45 -0
  13. package/esm/src/avatars/index.d.ts +1 -0
  14. package/esm/src/avatars/types/AvatarVisualDefinition.d.ts +6 -1
  15. package/esm/src/avatars/visuals/asciiOctopusAvatarVisual.d.ts +7 -0
  16. package/esm/src/avatars/visuals/avatarVisualRegistry.test.d.ts +1 -0
  17. package/esm/src/avatars/visuals/fractalAvatarVisual.d.ts +7 -0
  18. package/esm/src/avatars/visuals/octopus2AvatarVisual.d.ts +7 -0
  19. package/esm/src/avatars/visuals/octopus3AvatarVisual.d.ts +7 -0
  20. package/esm/src/avatars/visuals/octopusAvatarVisualShared.d.ts +125 -0
  21. package/esm/src/book-components/Chat/Chat/ChatMessageItem.d.ts +1 -1
  22. package/esm/src/book-components/Chat/Chat/ChatMessageList.d.ts +1 -1
  23. package/esm/src/book-components/Chat/Chat/ChatProps.d.ts +1 -1
  24. package/esm/src/book-components/Chat/Chat/ChatToolCallModalComponents.d.ts +8 -2
  25. package/esm/src/book-components/Chat/hooks/useChatCompleteNotification.d.ts +2 -0
  26. package/esm/src/book-components/Chat/types/ChatParticipant.d.ts +10 -0
  27. package/esm/src/cli/cli-commands/coder/ensureCoderGitignoreFile.d.ts +1 -1
  28. package/esm/src/config.d.ts +2 -2
  29. package/esm/src/llm-providers/agent/RemoteAgent.d.ts +3 -0
  30. package/esm/src/utils/agents/resolveAgentAvatarImageUrl.d.ts +49 -5
  31. package/esm/src/utils/agents/resolveAgentAvatarImageUrl.test.d.ts +1 -0
  32. package/esm/src/version.d.ts +1 -1
  33. package/package.json +4 -2
  34. package/umd/index.umd.js +883 -284
  35. package/umd/index.umd.js.map +1 -1
  36. package/umd/scripts/run-codex-prompts/common/waitForPause.d.ts +13 -1
  37. package/umd/scripts/run-codex-prompts/git/commitChanges.d.ts +3 -1
  38. package/umd/scripts/run-codex-prompts/ui/buildCoderRunOctopusVisual.d.ts +13 -0
  39. package/umd/scripts/run-codex-prompts/ui/buildCoderRunUiFrame.d.ts +3 -1
  40. package/umd/scripts/run-codex-prompts/ui/coderRunUiRefresh.d.ts +23 -0
  41. package/umd/scripts/run-codex-prompts/ui/coderRunUiText.d.ts +36 -0
  42. package/umd/scripts/run-codex-prompts/ui/renderCoderRunUi.d.ts +4 -3
  43. package/umd/scripts/utils/emojiTags/scanEmojiTagUsage.d.ts +51 -0
  44. package/umd/src/avatars/AvatarOrImage.d.ts +45 -0
  45. package/umd/src/avatars/index.d.ts +1 -0
  46. package/umd/src/avatars/types/AvatarVisualDefinition.d.ts +6 -1
  47. package/umd/src/avatars/visuals/asciiOctopusAvatarVisual.d.ts +7 -0
  48. package/umd/src/avatars/visuals/avatarVisualRegistry.test.d.ts +1 -0
  49. package/umd/src/avatars/visuals/fractalAvatarVisual.d.ts +7 -0
  50. package/umd/src/avatars/visuals/octopus2AvatarVisual.d.ts +7 -0
  51. package/umd/src/avatars/visuals/octopus3AvatarVisual.d.ts +7 -0
  52. package/umd/src/avatars/visuals/octopusAvatarVisualShared.d.ts +125 -0
  53. package/umd/src/book-components/Chat/Chat/ChatMessageItem.d.ts +1 -1
  54. package/umd/src/book-components/Chat/Chat/ChatMessageList.d.ts +1 -1
  55. package/umd/src/book-components/Chat/Chat/ChatProps.d.ts +1 -1
  56. package/umd/src/book-components/Chat/Chat/ChatToolCallModalComponents.d.ts +8 -2
  57. package/umd/src/book-components/Chat/hooks/useChatCompleteNotification.d.ts +2 -0
  58. package/umd/src/book-components/Chat/types/ChatParticipant.d.ts +10 -0
  59. package/umd/src/cli/cli-commands/coder/ensureCoderGitignoreFile.d.ts +1 -1
  60. package/umd/src/config.d.ts +2 -2
  61. package/umd/src/llm-providers/agent/RemoteAgent.d.ts +3 -0
  62. package/umd/src/utils/agents/resolveAgentAvatarImageUrl.d.ts +49 -5
  63. package/umd/src/utils/agents/resolveAgentAvatarImageUrl.test.d.ts +1 -0
  64. package/umd/src/version.d.ts +1 -1
@@ -1,3 +1,5 @@
1
+ import type { AvatarDefinition } from '../../avatars/types/AvatarDefinition';
2
+ import type { AvatarVisualId } from '../../avatars/types/AvatarVisualDefinition';
1
3
  import type { AgentBasicInformation } from '../../book-2.0/agent-source/AgentBasicInformation';
2
4
  import type { string_url, string_url_image } from '../../types/typeAliases';
3
5
  /**
@@ -5,25 +7,67 @@ import type { string_url, string_url_image } from '../../types/typeAliases';
5
7
  *
6
8
  * @private utility of `<Chat/>`
7
9
  */
8
- export type ResolveAgentAvatarImageUrlOptions = {
10
+ export type ResolveAgentAvatarOptions = {
9
11
  /**
10
12
  * Agent metadata used for avatar resolution.
11
13
  */
12
- readonly agent: Pick<AgentBasicInformation, 'agentName' | 'permanentId' | 'meta'>;
14
+ readonly agent: Pick<AgentBasicInformation, 'agentName' | 'agentHash' | 'permanentId' | 'meta'> & {
15
+ /**
16
+ * Optional explicit marker coming from remote profile payloads.
17
+ * When `false`, `meta.image` is treated as the generated static fallback rather than a user-defined `META IMAGE`.
18
+ */
19
+ readonly isMetaImageExplicit?: boolean;
20
+ /**
21
+ * Optional preferred avatar visual id coming from remote profile payloads.
22
+ */
23
+ readonly avatarVisualId?: AvatarVisualId;
24
+ };
13
25
  /**
14
26
  * Optional base URL used to resolve relative meta images and placeholders.
15
27
  */
16
28
  readonly baseUrl?: string_url;
17
29
  };
30
+ /**
31
+ * Backward-compatible alias kept for callers that only need image URLs.
32
+ *
33
+ * @private utility of `<Chat/>`
34
+ */
35
+ export type ResolveAgentAvatarImageUrlOptions = ResolveAgentAvatarOptions;
36
+ /**
37
+ * Default built-in avatar visual used when an agent does not define `META IMAGE`.
38
+ *
39
+ * @private shared avatar contract
40
+ */
41
+ export declare const DEFAULT_AGENT_AVATAR_VISUAL_ID: AvatarVisualId;
42
+ /**
43
+ * Resolved avatar descriptor used by interactive UIs to pick either an image or a live canvas visual.
44
+ *
45
+ * @private shared avatar contract
46
+ */
47
+ export type ResolvedAgentAvatar = {
48
+ readonly type: 'image';
49
+ readonly imageUrl: string_url_image;
50
+ } | {
51
+ readonly type: 'visual';
52
+ readonly avatarDefinition: AvatarDefinition;
53
+ readonly visualId: AvatarVisualId;
54
+ };
18
55
  /**
19
56
  * Resolve the fallback avatar URL for an agent.
20
57
  *
21
58
  * @private utility of `<Chat/>`
22
59
  */
23
- export declare function resolveAgentAvatarFallbackUrl(options: ResolveAgentAvatarImageUrlOptions): string_url_image | null;
60
+ export declare function resolveAgentAvatarFallbackUrl(options: ResolveAgentAvatarOptions): string_url_image | null;
61
+ /**
62
+ * Resolve the best avatar representation for an agent, preferring explicit `META IMAGE`
63
+ * and otherwise returning the default deterministic canvas visual.
64
+ *
65
+ * @private utility of `<Chat/>`
66
+ */
67
+ export declare function resolveAgentAvatar(options: ResolveAgentAvatarOptions): ResolvedAgentAvatar | null;
24
68
  /**
25
- * Resolve the best avatar URL for an agent, preferring META IMAGE and falling back to placeholders.
69
+ * Resolve the best avatar URL for an agent, preferring `META IMAGE` and falling back to the static placeholder route.
26
70
  *
27
71
  * @private utility of `<Chat/>`
28
72
  */
29
- export declare function resolveAgentAvatarImageUrl(options: ResolveAgentAvatarImageUrlOptions): string_url_image | null;
73
+ export declare function resolveAgentAvatarImageUrl(options: ResolveAgentAvatarOptions): string_url_image | null;
@@ -15,7 +15,7 @@ export declare const BOOK_LANGUAGE_VERSION: string_semantic_version;
15
15
  export declare const PROMPTBOOK_ENGINE_VERSION: string_promptbook_version;
16
16
  /**
17
17
  * Represents the version string of the Promptbook engine.
18
- * It follows semantic versioning (e.g., `0.112.0-44`).
18
+ * It follows semantic versioning (e.g., `0.112.0-46`).
19
19
  *
20
20
  * @generated
21
21
  */