# Recommended videos > **Source**: [Coherent](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ) ## Browse Collection 1. [What is Coherent Spark?](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/H5WYl7ZaNvgXCTrR0PTkJg.md) (Video) 2. [Crafting front end using Coherent Validation API](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/1DMjKEJmLUV6qPqTdFKIsQ.md) (Video) 3. [Traffic Director: Rating and Rules](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/I0g3sx3MrYnr3VdJIpQ2XA.md) (Video) 4. [Employee Benefits - Spark Shell ](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/wwkXuHO5AjyjQ9fTIawTyw.md) (Video) 5. [Tech 205: Integrating with LLM](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ.md) (Video) 6. [Batch API using Python SDK (Clone)](https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/8AYIt0ikqUJ4dhFayUnlfg.md) (Video) --- # VIDEO: Tech 205: Integrating with LLM ## METADATA - id: FeEnXeDvUcHvqoXP5ITiCQ - type: video - source: Coherent - content_url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ - collection_url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ ## TRANSCRIPT - time: 00:00 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=0 text: Hi, I'm Bryan O'Neal from Coherent. - time: 00:03 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=3 text: In this video, I'd like to show you a really neat usage pattern, - time: 00:06 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=6 text: which is to have an AI call - time: 00:08 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=8 text: your Excel model via the API that you've created in Coherent. - time: 00:13 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=13 text: Here's a simple spreadsheet that we've uploaded to Coherent - time: 00:16 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=16 text: that is a term life pricing model. - time: 00:20 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=20 text: You can see that the inputs are going to be your age, - time: 00:23 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=23 text: your gender, the term of the policy, - time: 00:25 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=25 text: smoker status, and sum assured. - time: 00:28 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=28 text: And when you ping the API, - time: 00:30 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=30 text: it basically gives you back your premium - time: 00:32 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=32 text: and a few other values here. - time: 00:34 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=34 text: This is actually really straightforward - time: 00:36 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=36 text: to integrate with an AI. - time: 00:38 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=38 text: And on this screen, - time: 00:39 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=39 text: you can see we've used OpenAI's GPT offering to do so. - time: 00:46 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=46 text: And it's pretty straightforward. - time: 00:48 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=48 text: Actually, all you have to do is put in a little prompt here. - time: 00:51 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=51 text: And notice in my prompt, it says, - time: 00:53 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=53 text: if they ask for a price, - time: 00:54 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=54 text: be sure to get them to give you - time: 00:56 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=56 text: all the required information. - time: 00:59 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=59 text: All right, so let's try this. - time: 01:00 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=60 text: Let's just say, please give me a term life quote. - time: 01:07 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=67 text: And it's gonna say, - time: 01:10 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=70 text: here's all the items that I need to know from you. - time: 01:14 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=74 text: So let's give it a hard time and say, - time: 01:17 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=77 text: I'm 45 male and I want 20 years coverage. - time: 01:23 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=83 text: It's not gonna bite. - time: 01:24 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=84 text: It's gonna say, I need those other two bits of information. - time: 01:27 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=87 text: So, okay, I'll finally say non smoker and one million. - time: 01:35 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=95 text: And it will make a call out to the Coherent API. - time: 01:38 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=98 text: You can see it's talking to Excel .coherent.global. - time: 01:41 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=101 text: And it returns my quote. Twenty nine hundred. - time: 01:45 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=105 text: Pretty neat. - time: 01:46 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=106 text: And this is a straightforward stylized demo, - time: 01:50 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=110 text: but really it would fit nicely - time: 01:53 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=113 text: within any kind of internal workflow, - time: 01:55 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=115 text: any kind of customer facing workflow. - time: 01:57 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=117 text: There's some controls you would need to put around it, - time: 01:59 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=119 text: but the general theme is that you can expose them - time: 02:01 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=121 text: to whatever business logic that is currently in Excel - time: 02:05 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=125 text: to your various AI pipelines. - time: 02:08 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=128 text: So if this use case fits into your ambitions, - time: 02:12 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=132 text: we'd love to help you implement it. - time: 02:14 url: https://coherent.portal.trainn.co/oGECFYpUljYdG0l0CZ6dMQ/FeEnXeDvUcHvqoXP5ITiCQ?start_time=134 text: Thanks for watching. ## SUMMARY # Integrating AI with Excel Models via Coherent API Hi, I'm Brian O'Neill from Coherent. In this video, I'd like to show you a really neat usage pattern, which is to have an AI call your Excel model via the API that you've created in Coherent. ## Overview of the Term Life Pricing Model Here's a simple spreadsheet that we've uploaded to Coherent that is a term life pricing model. The inputs for this model include: - Your age - Your gender - The term of the policy - Smoker status - The sum assured When you ping the API, it returns your premium and a few other values. This integration is straightforward to implement with an AI. ## Using AI with Coherent API On this screen, you can see we've used OpenAI's GPT offering to integrate with the Coherent API. The process is simple: 1. Enter a prompt in the AI interface. 2. Ensure the prompt requests all required information for a quote. For example, if you ask for a term life quote, the AI will prompt you for all necessary details. If you provide incomplete information, such as "I'm 45 male and I want 20 years coverage," the AI will request the missing details, like smoker status and sum assured. ## Demo Example Let's complete the information: non-smoker and 1,000,000. The AI then makes a call to the Coherent API, communicating with Excel.coherent.global, and returns the quote: 2,900. Pretty neat! ## Applications and Benefits This is a straightforward stylized demo, but it can be integrated into any internal or customer-facing workflow. While some controls are necessary, the main advantage is exposing your existing Excel business logic to various AI pipelines. If this use case aligns with your goals, we'd love to help you implement it. Thanks for watching!