@heroui/agent 0.2.0-beta.4 → 0.2.0-beta.6
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/CHANGELOG.md +12 -0
- package/README.md +7 -2
- package/dist/{chunk-5X2OXK4I.js → chunk-MUAFQBVY.js} +3 -2
- package/dist/{chunk-XBYPU7PM.js → chunk-QOCNMON2.js} +1 -0
- package/dist/contracts.d.ts +4 -3
- package/dist/contracts.js +8 -2
- package/dist/css/index.css +1 -1
- package/dist/{embed-runtime-WVXLM2KL.js → embed-runtime-CR7PQH3Q.js} +12 -3
- package/dist/{identity-CuhZgpvp.d.ts → identity-Z6i6pL0F.d.ts} +2 -0
- package/dist/index.d.ts +7 -1
- package/dist/index.js +2 -2
- package/dist/next.js +2 -2
- package/dist/server.d.ts +1 -1
- package/dist/server.js +7 -2
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.2.0-beta.6
|
|
4
|
+
|
|
5
|
+
- Add opt-in recent news results with `capabilities.newsSearch`, including dashboard-managed remote
|
|
6
|
+
configuration and every preload, message, retry, and transport path.
|
|
7
|
+
- Keep long activity-trail titles inside the Agent panel with a truncated label and a visible
|
|
8
|
+
disclosure control.
|
|
9
|
+
|
|
10
|
+
## 0.2.0-beta.5
|
|
11
|
+
|
|
12
|
+
- No SDK API or bundle changes from `0.2.0-beta.4`; this prerelease accompanies Agent runtime
|
|
13
|
+
deployment and CI configuration updates.
|
|
14
|
+
|
|
3
15
|
## 0.2.0-beta.4
|
|
4
16
|
|
|
5
17
|
- Add `reopenOnRefresh` and `startNewConversationOnOpen` controls for predictable panel and
|
package/README.md
CHANGED
|
@@ -24,7 +24,7 @@ import {HeroUIAgent} from "@heroui/agent/next";
|
|
|
24
24
|
export function AppAgent() {
|
|
25
25
|
return (
|
|
26
26
|
<HeroUIAgent
|
|
27
|
-
agentId=
|
|
27
|
+
agentId={process.env.NEXT_PUBLIC_HEROUI_AGENT_ID!}
|
|
28
28
|
getAuthToken={async (context) => {
|
|
29
29
|
const response = await fetch("/api/heroui-agent/auth-token", {
|
|
30
30
|
method: "POST",
|
|
@@ -149,7 +149,12 @@ const tools = [
|
|
|
149
149
|
}),
|
|
150
150
|
];
|
|
151
151
|
|
|
152
|
-
<HeroUIAgent
|
|
152
|
+
<HeroUIAgent
|
|
153
|
+
agentId={process.env.NEXT_PUBLIC_HEROUI_AGENT_ID!}
|
|
154
|
+
getAuthToken={getAuthToken}
|
|
155
|
+
context={{apiClient}}
|
|
156
|
+
tools={tools}
|
|
157
|
+
/>;
|
|
153
158
|
```
|
|
154
159
|
|
|
155
160
|
Only tool names, descriptions, and JSON schemas reach the hosted agent. Implementations and `context` never leave the browser.
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
resolveOptions,
|
|
11
11
|
scheduleIdleTask,
|
|
12
12
|
writeAgentShellHandoff
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-QOCNMON2.js";
|
|
14
14
|
|
|
15
15
|
// src/embed/provider.tsx
|
|
16
16
|
import {
|
|
@@ -243,6 +243,7 @@ function parseAgentRemoteConfig(value) {
|
|
|
243
243
|
const capabilities = group(
|
|
244
244
|
shape(value["capabilities"], {
|
|
245
245
|
imageSearch: optionalBoolean,
|
|
246
|
+
newsSearch: optionalBoolean,
|
|
246
247
|
webSearch: optionalBoolean
|
|
247
248
|
})
|
|
248
249
|
);
|
|
@@ -531,7 +532,7 @@ var embedRuntimePromise;
|
|
|
531
532
|
function loadEmbedRuntime() {
|
|
532
533
|
embedRuntimePromise ??= import(
|
|
533
534
|
/* webpackPrefetch: true */
|
|
534
|
-
"./embed-runtime-
|
|
535
|
+
"./embed-runtime-CR7PQH3Q.js"
|
|
535
536
|
).then(
|
|
536
537
|
(module) => module.default
|
|
537
538
|
);
|
|
@@ -1028,6 +1028,7 @@ function resolveOptions(props) {
|
|
|
1028
1028
|
}
|
|
1029
1029
|
} : {},
|
|
1030
1030
|
imageSearch: (props.capabilities?.webSearch ?? false) && (props.capabilities?.imageSearch ?? true),
|
|
1031
|
+
newsSearch: (props.capabilities?.webSearch ?? false) && (props.capabilities?.newsSearch ?? false),
|
|
1031
1032
|
suggestedPrompts: props.startScreen?.prompts?.map((prompt) => prompt.trim()).filter(Boolean).slice(0, 5),
|
|
1032
1033
|
themeStyle: {
|
|
1033
1034
|
...buildThemeStyle(props.appearance?.theme),
|
package/dist/contracts.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { T as TrustedAgentClientData, S as SignedTrustedAgentClientData } from './identity-
|
|
3
|
-
export { A as AGENT_CONVERSATION_SOURCE, a as AgentAuthIdentity, b as AgentAuthProfile, c as AgentAuthToken, d as AgentConversationSource, e as AgentProjectConfig, f as AgentSurfaceVariant, g as AgentTheme, h as AgentTokenClaims, C as CreateAgentAuthTokenRequest, i as agentAuthIdentitySchema, j as agentAuthProfileSchema, k as agentAuthTokenSchema, l as agentIdentityIdSchema, m as agentProjectConfigSchema, n as agentSurfaceVariantSchema, o as agentThemeSchema, p as agentTokenClaimsSchema, q as createAgentAuthTokenRequestSchema, r as pageContextSchema, s as signedTrustedAgentClientDataSchema, t as trustedAgentClientDataSchema } from './identity-
|
|
2
|
+
import { T as TrustedAgentClientData, S as SignedTrustedAgentClientData } from './identity-Z6i6pL0F.js';
|
|
3
|
+
export { A as AGENT_CONVERSATION_SOURCE, a as AgentAuthIdentity, b as AgentAuthProfile, c as AgentAuthToken, d as AgentConversationSource, e as AgentProjectConfig, f as AgentSurfaceVariant, g as AgentTheme, h as AgentTokenClaims, C as CreateAgentAuthTokenRequest, i as agentAuthIdentitySchema, j as agentAuthProfileSchema, k as agentAuthTokenSchema, l as agentIdentityIdSchema, m as agentProjectConfigSchema, n as agentSurfaceVariantSchema, o as agentThemeSchema, p as agentTokenClaimsSchema, q as createAgentAuthTokenRequestSchema, r as pageContextSchema, s as signedTrustedAgentClientDataSchema, t as trustedAgentClientDataSchema } from './identity-Z6i6pL0F.js';
|
|
4
4
|
import { UIMessage } from 'ai';
|
|
5
5
|
|
|
6
6
|
/** Maximum number of files accepted on one HeroUI Agent message. */
|
|
@@ -88,6 +88,7 @@ type AgentRemoteConfig = {
|
|
|
88
88
|
};
|
|
89
89
|
capabilities?: {
|
|
90
90
|
imageSearch?: boolean;
|
|
91
|
+
newsSearch?: boolean;
|
|
91
92
|
webSearch?: boolean;
|
|
92
93
|
};
|
|
93
94
|
composer?: {
|
|
@@ -1345,7 +1346,7 @@ declare function signTrustedAgentClientData(secret: string, data: TrustedAgentCl
|
|
|
1345
1346
|
declare function verifyTrustedAgentClientData(secret: string, value: unknown): Promise<TrustedAgentClientData | null>;
|
|
1346
1347
|
|
|
1347
1348
|
declare const HEROUI_AGENT_PROTOCOL_VERSION: 5;
|
|
1348
|
-
declare const HEROUI_AGENT_SDK_VERSION: "0.2.0-beta.
|
|
1349
|
+
declare const HEROUI_AGENT_SDK_VERSION: "0.2.0-beta.6";
|
|
1349
1350
|
declare const HEROUI_AGENT_TASK_ID: "heroui-agents-runtime";
|
|
1350
1351
|
declare const TRUSTED_AGENT_CLIENT_DATA_KEY: "__heroUiAgentApi";
|
|
1351
1352
|
|
package/dist/contracts.js
CHANGED
|
@@ -180,6 +180,7 @@ function parseAgentRemoteConfig(value) {
|
|
|
180
180
|
const capabilities = group(
|
|
181
181
|
shape(value["capabilities"], {
|
|
182
182
|
imageSearch: optionalBoolean,
|
|
183
|
+
newsSearch: optionalBoolean,
|
|
183
184
|
webSearch: optionalBoolean
|
|
184
185
|
})
|
|
185
186
|
);
|
|
@@ -2184,7 +2185,7 @@ var agentModelIdSchema = z3.preprocess(
|
|
|
2184
2185
|
|
|
2185
2186
|
// src/contracts/version.ts
|
|
2186
2187
|
var HEROUI_AGENT_PROTOCOL_VERSION = 5;
|
|
2187
|
-
var HEROUI_AGENT_SDK_VERSION = "0.2.0-beta.
|
|
2188
|
+
var HEROUI_AGENT_SDK_VERSION = "0.2.0-beta.6";
|
|
2188
2189
|
var HEROUI_AGENT_TASK_ID = "heroui-agents-runtime";
|
|
2189
2190
|
var TRUSTED_AGENT_CLIENT_DATA_KEY = "__heroUiAgentApi";
|
|
2190
2191
|
|
|
@@ -2283,6 +2284,11 @@ var trustedAgentClientDataSchema = z4.object({
|
|
|
2283
2284
|
* fixed agent allowlist and signs the value before the runtime sees it.
|
|
2284
2285
|
*/
|
|
2285
2286
|
modelId: agentModelIdSchema.optional(),
|
|
2287
|
+
/**
|
|
2288
|
+
* When web search is enabled, allow recent news results via `includeNews`.
|
|
2289
|
+
* Optional and disabled when omitted so older signed payloads remain valid.
|
|
2290
|
+
*/
|
|
2291
|
+
newsSearch: z4.boolean().optional(),
|
|
2286
2292
|
pageContext: pageContextSchema.default({}),
|
|
2287
2293
|
/**
|
|
2288
2294
|
* Set by the API when the session was authorized by a dashboard preview
|
|
@@ -2299,7 +2305,7 @@ var trustedAgentClientDataSchema = z4.object({
|
|
|
2299
2305
|
/**
|
|
2300
2306
|
* Host-enabled public web search. When true the runtime registers the
|
|
2301
2307
|
* `searchWeb` tool (if the search backend is configured) so the agent can
|
|
2302
|
-
* look up public information and
|
|
2308
|
+
* look up public information, images, and optionally news. Optional (not defaulted) so schema
|
|
2303
2309
|
* parsing never injects a field into an already-signed payload.
|
|
2304
2310
|
*/
|
|
2305
2311
|
webSearch: z4.boolean().optional()
|