Skip to content

Commit

Permalink
Detect search query to start webchat (#333)
Browse files Browse the repository at this point in the history
(cherry picked from commit ggerganov/llama.cpp@400d5d7)
  • Loading branch information
Mardak authored and jart committed Apr 13, 2024
1 parent 55e178f commit d28daf2
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions llama.cpp/server/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1001,6 +1001,10 @@
}

function App(props) {
useEffect(() => {
const query = new URLSearchParams(location.search).get("q");
if (query) chat(query);
}, []);

return html`
<div class="mode-${session.value.type}">
Expand Down

0 comments on commit d28daf2

Please sign in to comment.