Live data from Hacker News

Show HN: Symphony – Use GPT-4 to call functions in sequence

symphony.run

11–20 of 36 posts

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#12
post #7

Nice. Just to point out, calling a sequence of functions is what GPT-4 does automatically if you keep feeding it the responses and it is clear to it that is necessary given it's instructions. So the main point of this seems to be extracting the interface from the module and converting it into the OpenAI API call's functions format. It's a good idea. But for me I would rather just have an npm package with a function l…

Yep. I built this for Python recently and it uses introspection to automatically build this same info. It's maybe 100 lines in total? The OpenAI API is pretty amazing.

Have you packaged or shared your codebase? If so would love to see it!

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#13
I tried TypeChat for my use case and ended up defining functions as typescript data types. This approach sounds much better, and leverages the newer OpenAI function calling, which should be more reliable I would think. Thanks for creating+sharing.

https://microsoft.github.io/TypeChat/

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#14
post #6

Earlier quoted context omitted.

Pretty cool that this is a recreation of expert systems, which was a dominant approach to building AIs for decades :)

Expert systems except it's like 400 times more expensive to run.

Sure, but also 400 times (at least...) more versatile and more error prone.

Determinism was one of the things that the expert systems of old did reasonably well. The current incarnation feels like playing Russian Roulette but with three bullets rather than just one.

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#15
post #7

Nice. Just to point out, calling a sequence of functions is what GPT-4 does automatically if you keep feeding it the responses and it is clear to it that is necessary given it's instructions. So the main point of this seems to be extracting the interface from the module and converting it into the OpenAI API call's functions format. It's a good idea. But for me I would rather just have an npm package with a function l…

Well, this knows when to stop calling GPT-4, which seems non-trivial.

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#16
post #15
post #7

Nice. Just to point out, calling a sequence of functions is what GPT-4 does automatically if you keep feeding it the responses and it is clear to it that is necessary given it's instructions. So the main point of this seems to be extracting the interface from the module and converting it into the OpenAI API call's functions format. It's a good idea. But for me I would rather just have an npm package with a function l…

Well, this knows when to stop calling GPT-4, which seems non-trivial.

ChatGPT does this automatically, if you pass in `function_call: "auto"`

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#17
post #7

Nice. Just to point out, calling a sequence of functions is what GPT-4 does automatically if you keep feeding it the responses and it is clear to it that is necessary given it's instructions. So the main point of this seems to be extracting the interface from the module and converting it into the OpenAI API call's functions format. It's a good idea. But for me I would rather just have an npm package with a function l…

Thank you! You're right; the main focus right now is extraction.

One aspect I'm excited about is the possibility of rendering the JSON outputs from these function calls into UI components, as previewed here: https://symphony.run/showcase. Using a function's type definitions is a nice starting point to embed interfaces into the conversation.

Additionally, I hope to make the toolkit language-agnostic. I'd like to incorporate some of my .py and .rs scripts to make them ready for use as well. Not sure if packaging it as an npm package would go against that objective, but will definitely consider :)

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#18
post #7

Nice. Just to point out, calling a sequence of functions is what GPT-4 does automatically if you keep feeding it the responses and it is clear to it that is necessary given it's instructions. So the main point of this seems to be extracting the interface from the module and converting it into the OpenAI API call's functions format. It's a good idea. But for me I would rather just have an npm package with a function l…

Yep. I built this for Python recently and it uses introspection to automatically build this same info. It's maybe 100 lines in total? The OpenAI API is pretty amazing.

That sounds great! I'm currently working on adding support for .py files as well – open to PRs :)

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#19
post #2

If I'm understanding correctly, this makes all of the functions available to gpt-4 at once and then gpt-4 decides which one to use, right? What are the limits on the number and length of functions, and is there any way to choose only a subject of the functions to share for a given user query?

You're right!

IIRC, only the function signatures (or descriptions) are counted as part of the context window so you could add as many till you exceed that limit. Since the contents of the function itself are not counted, your function can be whatever length.

> is there any way to choose only a subject of the functions to share for a given user query?

As of now, no. I can see why this may be a problem soon since right now all functions are available for gpt-4 and each call can become expensive pretty quickly if you send like 50 functions every time.

I'm not sure how to address this yet, but I'd like to think of it as some form of fine-tuning that happens after having a few conversations. Will keep you in the loop!

Re: Show HN: Symphony – Use GPT-4 to call functions in sequence

#20
post #8

Is there still an absolutely pathetic amount of GPT4 calls per day? I pay the $20 to chatgpt but I never ever pick GPT4 because 10 minutes into an AI directed conversation I'll get the "sorry ur out of gpt4 today" message. The only time I wind up using that limit is when I don't even realize it's using it. I have no idea what the difference actually is because its limit is to low for me to even consider relying on ov…

No it's been OK the last month or 2
Post reply on HN