Sync upstream updates: sub-agent tool failures, Scout PostgreSQL full-text search and head Open Graph defaults
Merged
BI
10h ago+3341+3341+0123456789012345678901234567890123456789-482-482-012345678901234567890123456789
Upstream Updates
- Run a failed broadcast agent's catch callbacks even when broadcasting the "stream_failed" event throws.
- Let the moderation provider option override the "low" default for OpenAI gpt-image generations and edits and Azure OpenAI generations.
- Handle a sub-agent that throws like any other failed tool call. The tool loop dispatches ToolFailed, reports the exception and gives the parent a failed tool result, hiding the message outside debug mode. Cancellation is never turned into a tool failure, and Hypervel's concurrent streamed tool calls recover the same way. The sub-agent docs point to the tool failure docs.
- Continue stored Gemini interactions: with the store provider option, the next step sends previous_interaction_id and only the new function results.
- Generate conversation titles with ConversationTitleAgent, resolved from the container so apps can bind their own, and fake it when the conversation's agent is faked, so titles don't use the agent's fake responses. The docs cover the title agent, titling conversations an app creates, binding a replacement and title fakes.
- Reuse the Anthropic code execution container across tool loop steps unless provider options set one.
- Add native PostgreSQL full-text search to the Scout database engine: stored tsvector columns, tsquery modes including raw tsquery, language and ranking options, and pg_trgm trigram matching as a fallback or blended into the results. Options come from the SearchUsingFullText attribute and can be overridden per query. The searchable() and dropSearchable() Blueprint macros add or drop a generated, weighted tsvector column with its indexes. Hypervel binds the language as a parameter and caches the pg_trgm check on the engine and the attribute options per model.
- Wrap Typesense filter values that contain &&, ||, parentheses, commas or backticks in backticks, removing any backticks from the value. Array where values are raw filter expressions again, so geo filters reach Typesense as location:(...) instead of the location:=(...) Typesense rejects.
- Add the SearchableAs attribute for setting a model's index name. The name gets scout.prefix like the table name, and child models inherit it. A cached attribute check skips reflection for models without it, and the Scout docs show the attribute.
- Collapse a generated function's multi-line arguments onto one line when an argument type contains parentheses, such as import('@/types').Key<...>.
- Test the generated QUERY method on Route::redirect() routes, which register every verb. Hypervel already generated it.
- Event::location() takes only a schema object, as merged upstream. Hypervel had ported the draft, which turned a string into a bare Place, but Google requires an address for a physical location. Online events pass a VirtualLocation.
- Combine default Open Graph media from several defaults() calls instead of keeping only the last call's. Media a route, page or error defines still replaces it, and runtime default media still replaces registered default media, as the runtime defaults docs promise.
- Add the protected currentContainer() extension point that state() and request() resolve through. It returns the injected container: a Hypervel worker keeps one container and scopes head state per coroutine, so upstream's per-request container lookup isn't needed.
- Remove the og:url fallback from the head README's differences, since upstream now falls back to the canonical URL as Hypervel already did.
- Name Mailtrap Email Sandbox in the mail docs' local development section.
- Warn that Blade escapes HTML but not Markdown, so user input can inject Markdown into a Markdown mailable, and show Markdown::withSecuredEncoding().
- Document afterQuery() callbacks. The example hides an attribute with makeHidden() instead of setting a new property, which would make each model dirty, and the local scope suggestion is left out because pluck() passes the plucked values to the callback.
- Replace the Preferred Value Ordering section with upstream's Sequence Ordering section for inOrderOf().
- Note that Fortify adds throttle middleware to its login route when a login rate limiter is configured.
- Correct what a streamed parent response includes from its sub-agents. Sub-agent usage comes from the AgentStreamed event, or AgentPrompted for a sub-agent with structured output, which doesn't stream.
- Link the MCP Security Best Practices guide.
- Replace the MCP structured content paragraph with upstream's assertion section and table.
- Add a PHP requirements section to the deployment docs that links to the installation requirements instead of keeping its own list, which had drifted.
- Document HtmlString for unescaped Blade output.
- Use upstream's wording for inserting global and group middleware with insertBefore() and insertAfter().
- Say that bearerToken() returns null when the request has no bearer token.
Additional Hypervel changes
- Stop continuing a provider-stored response after step middleware edits a step's messages, for Gemini, OpenAI and xAI. The provider stored the edited history, which later steps must not inherit.
- Keep the Anthropic container's continuation token when a step changes its history, model or instructions. Upstream dropped it, so a second-step withInstructions() opened a new container and lost its files.
- Pass the provider instance to the conversation title agent, so a provider created on demand keeps its credentials, and resolve the title agent inside the title fallback, so a failing binding doesn't lose the completed turn.
- Keep simple pagination of Scout PostgreSQL searches on full-text results. Upstream switched to trigram matching on an empty later page while full-text search had matches, mixing two result sets.
- Keep explicit operators on Typesense array where values. Upstream dropped them, so a != filter became a positive match.
- Keep rows with a null column in PostgreSQL multi-column whereFullText() searches and Scout expression searches. Each column's vector is wrapped in coalesce(..., ''::tsvector), and multi-column full-text indexes use the same expression so searches can use them. The porting guide notes that existing multi-column full-text indexes must be recreated.
- Read the columns that Scout's searchable() macro and nested set's schema macros add and drop in PHPStan's migration reader, so models on those tables keep typed attributes. An application macro with the same name stays unknown, and replacing a macro invalidates the migration cache.
- Add the PHP extensions that hypervel/framework's packages and dependencies require to the installation requirements: Ctype, DOM, iconv, libxml, PCRE, SimpleXML and Sockets.
Summary by cubic
Syncs upstream updates across the AI SDK, Scout, database, head, Wayfinder, PHPStan, and mail packages, plus their documentation.
- Handles a failing sub-agent like any other tool failure: the parent gets a failed tool result, the exception is reported, and the message stays hidden outside debug mode; a sub-agent's validation failure fails the tool call too, and cancellation is never wrapped as a tool failure.
- Generates conversation titles with
ConversationTitleAgent, resolvable from the container so apps can bind their own, and fakes titles when the conversation's agent is faked. - Continues stored Gemini interactions by sending
previous_interaction_idwith only the new function results on the next step. - Keeps the Anthropic code execution container across tool loop steps; a step response that doesn't name a container keeps the one its request used, unless provider options set one.
- Makes the moderation provider option override the
lowdefault for OpenAI gpt-image generations and edits and Azure OpenAI generations. - Runs a failed broadcast agent's catch callbacks even when broadcasting the
stream_failedevent throws. - Adds native PostgreSQL full-text search to the Scout database engine: stored tsvector columns, tsquery modes, language and ranking options, and pg_trgm trigram matching.
searchable()anddropSearchable()Blueprint macros add or drop the generated weighted column, with overlong generated index names shortened by a hash; the PHPStan migration reader knows these macros. - Adds
SearchableAsfor setting a model's index name, with thescout.prefixapplied and child models inheriting it. - Wraps Typesense filter values containing special characters in backticks, sends quoted equality filters as one-member lists, and treats array where values as raw filter expressions again, so geo filters reach Typesense as
location:(...). Runs these tests against Typesense 30.1, the first version to support field-levelsymbols_to_index. - Merges Open Graph media across several
defaults()calls instead of keeping only the last call's; route, page, error, and runtime default media still replace it. - Makes
Event::location()accept only a schema object, since Google requires an address for a physical location; online events pass aVirtualLocation. - Adds the protected
currentContainer()extension point thatstate()andrequest()resolve through. - Moves CREATE foreign keys after their targets instead of promoting the targets, so the targets' own dependencies keep their written order.
- Collapses multi-line Wayfinder arguments containing parentheses and tests the generated QUERY method on redirect routes.
- Encodes ampersands and quotes in secured Markdown mail, so interpolated values can't introduce tags, attributes, or entities.
Hypervel fixes
- Stops continuing a provider-stored response after step middleware edits a step's messages, for Gemini, OpenAI, and xAI, since the provider stored the edited history that later steps must not inherit.
- Keeps the Anthropic container's continuation token when a step changes its history, model, or instructions, and keeps stored Gemini interaction continuation across step changes.
- Keeps simple Scout pagination on full-text results instead of switching to trigram matching on an empty later page.
- Keeps explicit operators on Typesense array where values, so a
!=filter doesn't become a positive match. - Wraps each column in
coalesce(..., ''::tsvector)for PostgreSQL multi-columnwhereFullText()searches and full-text indexes, so a null column no longer hides a row; existing multi-column full-text indexes must be recreated. - Fixes
dropSearchable()on schema-prefixed tables and shortens overlong generated searchable index names with a hash so they don't collide after PostgreSQL's 63-byte identifier truncation. - Reads Scout's
searchable()and nested set's schema macros in PHPStan's migration reader, and invalidates the migration cache when an application replaces a first-party macro. - Adds the PHP extensions hypervel/framework requires (Ctype, DOM, iconv, libxml, PCRE, SimpleXML, Sockets) to the installation requirements.
[!NOTE]
Add Scout PostgreSQL full-text search, sub-agent tool failures, and Open Graph defaults fixes
- Adds PostgreSQL full-text search support to Scout's
DatabaseEngine: weighted stored tsvector columns and GIN indexes via new searchable/dropSearchable blueprint macros, SearchUsingFullText options, trigram fallback/blend modes, and a SearchableAs attribute for index names
- Fixes null-column handling:
PostgresGrammar now coalesces each tsvector before concatenation in multi-column full-text queries and indexes, so a null column no longer hides a row
- Changes sub-agent failures to fail the tool call:
AgentTool now propagates exceptions, TextGenerationLoop and InvokesTools record them as failed tool results, and BroadcastAgent.failed runs catch callbacks even when the error broadcast throws
- Title generation now uses the new
ConversationTitleAgent, and head defaults accumulate across multiple defaults() calls instead of being replaced
- Adds
ReplaysFullHistory gateway contract; Anthropic and Gemini gateways carry container/interaction continuation tokens across steps
- Risk:
Event::location in Event.php no longer accepts strings (only SchemaObject), and multi-column full-text indexes created with Laravel's grammar must be recreated to be used
Macroscope summarized 2c6b923.
Summary by CodeRabbit
- New Features
- Conversations can receive concise, automatically generated titles, with fallback titles when generation fails.
- PostgreSQL search now supports configurable full-text and trigram matching, stored search vectors, and custom search index names.
- Image generation requests can specify a moderation setting.
- Bug Fixes
- PostgreSQL full-text searches can match rows when some searched columns are null.
- Search filters better handle values containing special characters.
- AI tool failures are reported consistently, and provider follow-up requests preserve continuation state.
- Generated TypeScript route helpers better handle nested function arguments.
- Documentation
- Expanded guidance for search, middleware, queries, mail, deployment, and other features.