@kokimoki/app 2.0.2 → 2.1.0

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.
package/dist/llms.txt CHANGED
@@ -330,6 +330,8 @@ const { content } = await kmClient.ai.chat({
330
330
 
331
331
  Used to generate structured JSON output with AI. Automatically ensures the response is valid JSON and parses it for you.
332
332
 
333
+ **Important:** Your prompt must include the word "json" and should describe the expected output schema (field names, types, and structure) to ensure the AI generates properly formatted responses.
334
+
333
335
  **Parameters:**
334
336
 
335
337
  - **req.model**: `string` AI model to use (optional). Available models:
@@ -69,6 +69,8 @@ export declare class KokimokiAiService {
69
69
  * - `gpt-5-nano`: Smallest GPT-5 variant for lightweight tasks
70
70
  * - `gemini-2.5-flash-lite`: Google Gemini lite variant
71
71
  * - `gemini-2.5-flash`: Google Gemini fast variant
72
+ * - `gemini-3-flash-preview`: Google Gemini 3 Flash preview
73
+ * - `gemini-3-pro-preview`: Google Gemini 3 Pro preview
72
74
  * @param req.systemPrompt Optional. The system message that sets the behavior and context for the AI.
73
75
  * This helps define the AI's role, personality, and constraints.
74
76
  * @param req.userPrompt The user's message or question to send to the AI.
@@ -96,12 +98,14 @@ export declare class KokimokiAiService {
96
98
  * ```
97
99
  */
98
100
  chat(req: {
99
- model?: "gpt-4o" | "gpt-4o-mini" | "gpt-5" | "gpt-5-mini" | "gpt-5-nano" | "gemini-2.5-flash-lite" | "gemini-2.5-flash";
101
+ model?: "gpt-4o" | "gpt-4o-mini" | "gpt-5" | "gpt-5-mini" | "gpt-5-nano" | "gemini-2.5-flash-lite" | "gemini-2.5-flash" | "gemini-3-flash-preview" | "gemini-3-pro-preview";
100
102
  systemPrompt?: string;
101
103
  userPrompt: string;
102
104
  temperature?: number;
103
105
  maxTokens?: number;
104
106
  responseMimeType?: string;
107
+ /** Image URLs to include with the user prompt (Gemini models only) */
108
+ imageUrls?: string[];
105
109
  }): Promise<{
106
110
  content: string;
107
111
  }>;
@@ -112,6 +116,10 @@ export declare class KokimokiAiService {
112
116
  * a JSON-formatted response. This is useful for scenarios where the output
113
117
  * needs to be parsed or processed programmatically.
114
118
  *
119
+ * **Important:** Your prompt must include the word "json" and should describe
120
+ * the expected output schema (field names, types, and structure) to ensure
121
+ * the AI generates properly formatted responses.
122
+ *
115
123
  * @param req The chat request parameters.
116
124
  * @param req.model Optional. The AI model to use. Defaults to server-side default if not specified.
117
125
  * Available models:
@@ -122,6 +130,8 @@ export declare class KokimokiAiService {
122
130
  * - `gpt-5-nano`: Smallest GPT-5 variant for lightweight tasks
123
131
  * - `gemini-2.5-flash-lite`: Google Gemini lite variant
124
132
  * - `gemini-2.5-flash`: Google Gemini fast variant
133
+ * - `gemini-3-flash-preview`: Google Gemini 3 Flash preview
134
+ * - `gemini-3-pro-preview`: Google Gemini 3 Pro preview
125
135
  * @param req.systemPrompt Optional. The system message that sets the behavior and context for the AI.
126
136
  * This helps define the AI's role, personality, and constraints.
127
137
  * @param req.userPrompt The user's message or question to send to the AI.
@@ -130,17 +140,21 @@ export declare class KokimokiAiService {
130
140
  * higher values make it more creative and varied.
131
141
  * @param req.maxTokens Optional. The maximum number of tokens to generate in the response.
132
142
  * Controls the length of the AI's output.
143
+ * @param req.imageUrls Optional. Image URLs to include with the user prompt (Gemini models only).
144
+ * Allows the AI to analyze images and generate structured JSON based on them.
133
145
  *
134
146
  * @returns A promise that resolves to the parsed JSON object generated by the AI.
135
147
  *
136
148
  * @throws An error object if the API request fails or if the response is not valid JSON.
137
149
  */
138
150
  generateJson<T extends object>(req: {
139
- model?: "gpt-4o" | "gpt-4o-mini" | "gpt-5" | "gpt-5-mini" | "gpt-5-nano" | "gemini-2.5-flash-lite" | "gemini-2.5-flash";
151
+ model?: "gpt-4o" | "gpt-4o-mini" | "gpt-5" | "gpt-5-mini" | "gpt-5-nano" | "gemini-2.5-flash-lite" | "gemini-2.5-flash" | "gemini-3-flash-preview" | "gemini-3-pro-preview";
140
152
  systemPrompt?: string;
141
153
  userPrompt: string;
142
154
  temperature?: number;
143
155
  maxTokens?: number;
156
+ /** Image URLs to include with the user prompt (Gemini models only) */
157
+ imageUrls?: string[];
144
158
  }): Promise<T>;
145
159
  /**
146
160
  * Modify an image using the AI service.
@@ -69,6 +69,8 @@ export class KokimokiAiService {
69
69
  * - `gpt-5-nano`: Smallest GPT-5 variant for lightweight tasks
70
70
  * - `gemini-2.5-flash-lite`: Google Gemini lite variant
71
71
  * - `gemini-2.5-flash`: Google Gemini fast variant
72
+ * - `gemini-3-flash-preview`: Google Gemini 3 Flash preview
73
+ * - `gemini-3-pro-preview`: Google Gemini 3 Pro preview
72
74
  * @param req.systemPrompt Optional. The system message that sets the behavior and context for the AI.
73
75
  * This helps define the AI's role, personality, and constraints.
74
76
  * @param req.userPrompt The user's message or question to send to the AI.
@@ -113,6 +115,10 @@ export class KokimokiAiService {
113
115
  * a JSON-formatted response. This is useful for scenarios where the output
114
116
  * needs to be parsed or processed programmatically.
115
117
  *
118
+ * **Important:** Your prompt must include the word "json" and should describe
119
+ * the expected output schema (field names, types, and structure) to ensure
120
+ * the AI generates properly formatted responses.
121
+ *
116
122
  * @param req The chat request parameters.
117
123
  * @param req.model Optional. The AI model to use. Defaults to server-side default if not specified.
118
124
  * Available models:
@@ -123,6 +129,8 @@ export class KokimokiAiService {
123
129
  * - `gpt-5-nano`: Smallest GPT-5 variant for lightweight tasks
124
130
  * - `gemini-2.5-flash-lite`: Google Gemini lite variant
125
131
  * - `gemini-2.5-flash`: Google Gemini fast variant
132
+ * - `gemini-3-flash-preview`: Google Gemini 3 Flash preview
133
+ * - `gemini-3-pro-preview`: Google Gemini 3 Pro preview
126
134
  * @param req.systemPrompt Optional. The system message that sets the behavior and context for the AI.
127
135
  * This helps define the AI's role, personality, and constraints.
128
136
  * @param req.userPrompt The user's message or question to send to the AI.
@@ -131,6 +139,8 @@ export class KokimokiAiService {
131
139
  * higher values make it more creative and varied.
132
140
  * @param req.maxTokens Optional. The maximum number of tokens to generate in the response.
133
141
  * Controls the length of the AI's output.
142
+ * @param req.imageUrls Optional. Image URLs to include with the user prompt (Gemini models only).
143
+ * Allows the AI to analyze images and generate structured JSON based on them.
134
144
  *
135
145
  * @returns A promise that resolves to the parsed JSON object generated by the AI.
136
146
  *
package/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const KOKIMOKI_APP_VERSION = "2.0.2";
1
+ export declare const KOKIMOKI_APP_VERSION = "2.1.0";
package/dist/version.js CHANGED
@@ -1,2 +1,2 @@
1
1
  // Auto-generated file. Do not edit manually.
2
- export const KOKIMOKI_APP_VERSION = '2.0.2';
2
+ export const KOKIMOKI_APP_VERSION = '2.1.0';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kokimoki/app",
3
- "version": "2.0.2",
3
+ "version": "2.1.0",
4
4
  "type": "module",
5
5
  "description": "Kokimoki app",
6
6
  "main": "dist/index.js",