Full Transcript

·YouTLDR

Lessons from building evals in Healthcare at Scale with Clara Matos

20:03EnglishTranscribed Jul 24, 2026
0:01

[music]

0:05

Next speaker is here [music] Clara

0:06

Matauss um from Sword Health and I'm

0:09

super interested to hear lessons from

0:10

building evals [music] in healthcare at

0:12

scale. So over to you.

0:15

>> So hi everyone, my name is Clara and I

0:17

work at Sword Health and today I'm going

0:19

to talk about lessons learned from

0:21

building with evolves in healthcare at

0:23

scale. So when developed and deployed

0:26

effectively, large language models have

0:27

the potential to increase access and

0:30

quality of care. However, we need to

0:32

guarantee that models remain safe,

0:34

reliable, and useful both before and

0:36

after they reach patients. A way to

0:39

achieve this is through both uh offline

0:42

and online evaluations. So you might

0:45

wonder why is evaluation in healthcare

0:47

hard? So models need to communicate

0:50

naturally with patients. They need to

0:52

respect clinical boundaries and they

0:54

need to fit within clinicians uh

0:56

workflows. So we need uh evaluations

0:59

that capture the complexity of care with

1:02

messy inputs and long-term outcomes. So

1:05

in this talk I'm going to cover how we

1:08

apply an eval driven development to

1:09

Phoenix our AI care specialist by first

1:13

giving an overview about uh Phoenix then

1:16

uh covering why are important and then

1:19

uh touching on both offline and online

1:22

evaluations so evaluations that are

1:24

performed before and after release.

1:29

So Phoenix is our AI care specialist

1:32

that is designed to bring clinical

1:34

expertise into every interaction. It

1:37

supports patients both both during and

1:39

between uh sessions.

1:43

Um so during uh sessions, Phoenix acts

1:46

as a true companion. It greets the

1:48

patient um sets expectations and follows

1:52

up on uh previous uh progress. As it as

1:56

exercises unfold, Phoenix answers

1:58

questions, responds to voice comments,

2:00

and provides feedback uh based on uh

2:03

motion uh tracking data. Um the outcome

2:07

is a smooth and true one-on-one

2:09

experience.

2:11

So between sessions, Phoenix continues

2:13

to play an active uh role by augmenting

2:16

clinicians

2:17

with by augmenting clinicians allowing

2:19

care to scale without compromising

2:22

quality among other among other things.

2:24

Fenix is able to uh make recommendations

2:28

to uh clinicians uh detect signs of of

2:31

disengagement and prompt clinicians to

2:34

reach out to members at the right time.

2:37

So everything that Fenix says uh when it

2:41

says and uh what it says is uh validated

2:46

both before and after release with

2:48

offline and online evaluations.

2:52

So first why are uh evolves important?

2:55

So the lack of evaluations has been a

2:57

key challenging in deploying large

2:58

language models to production. So

3:00

testing large language models as we all

3:02

know is hard and often slows down

3:05

development velocity. So we need to uh

3:08

measure the performance of these models

3:10

in real scenarios to increase confidence

3:13

as they are deployed at scale and in

3:16

high stake situations.

3:19

So what which are the main benefits of

3:22

evaluations? So first iterative improve

3:25

improvement is my V v2 better than my V1

3:29

also quality assurance before and after

3:32

um release. So uh has my latest model

3:35

introduced any regression?

3:38

Also objective model comparison. Can I

3:40

switch to another model and maintain or

3:42

even improve my current performance? And

3:45

finally potential cost savings. So can I

3:48

switch to a smaller model um and

3:50

maintain or even improve my current

3:52

performance.

3:54

So this is the process that we follow

3:56

and the one that I'm going to touch on

3:58

uh in the next slides. So I'm first

4:01

going to start by speaking about offline

4:03

evaluations, those that are performed

4:05

before release and then online

4:07

evaluations, those that are performed

4:09

after release.

4:11

So first offline evaluations. So when uh

4:15

developing with large uh language

4:17

models, we follow this iterative

4:19

process. So we first start by building

4:21

the evaluation data set by collecting

4:23

examples, defining the evaluation

4:25

criteria and uh performing human

4:28

annotation. Then we develop uh the a

4:32

suit of evaluators which can be called

4:35

human or llmas base. And finally before

4:38

release we perform a round of b check to

4:41

make sure that our release meets the

4:43

standards in quality and consistency and

4:46

at the same time that new issues that

4:48

are not yet covered by the evaluations

4:50

appear.

4:52

If all checks pass, we release the new

4:54

and hopefully improved version to

4:57

production.

4:59

So starting to speak about how to build

5:01

evaluation data sets. So when real data

5:04

is available, a common first step is to

5:06

collect examples at random. However,

5:08

this usually uh results in data sets

5:11

that are over represented with simple

5:13

and uh common use cases. In order to

5:16

avoid this, we try to create evaluation

5:18

data sets by gathering uh different

5:21

types of examples. So challenging

5:23

examples, rare examples, examples that

5:26

stress test different parts of the

5:27

application such as tool calling uh rag

5:30

or different prompt branches and um also

5:34

examples that are representative of

5:36

issues that have been previously uh

5:38

solved

5:40

for new features when no real data is

5:42

available. This evol data set can also

5:44

be built uh using synthetic uh examples.

5:48

Even when synthetic examples are uh

5:50

available um sorry even when real data

5:53

is available synthetic examples can be

5:56

used to uh create examples that are long

5:59

tail or that are rare and that haven't

6:02

yet appeared in uh production.

6:05

So this is an example of an item of the

6:08

evaluation that the set that we use to

6:10

evaluate Fenix conversations. So we

6:13

include the same context that is passed

6:15

to the model as well as the conversation

6:18

transcript between Phoenix and the

6:20

patient.

6:22

Over time these data sets is

6:24

continuously improved with new examples

6:27

collected uh either through user

6:29

feedback or manual audits.

6:33

Then we have we collect our examples.

6:36

The next step is to define evaluation

6:38

criterion. So for each feature we define

6:41

a set of uh criteria that define what

6:44

what success uh looks like. We always

6:46

try to keep outputs uh binary. So

6:49

something like yes or no, pass or fail

6:52

to uh reduce ambiguity and improve um

6:55

alignment. So this is an example um this

6:58

is an example of uh criteria that we use

7:01

to make sure that uh Phoenix remains

7:04

with an appropriate tone during

7:06

conversations.

7:09

Um so as we know the success of

7:11

evaluation depends on making sure that

7:13

these uh evaluators are aligned with

7:16

expert judgment. So in order to

7:18

guarantee that we perform human

7:21

annotation on the collected examples. So

7:24

we can use a single annotator or

7:26

multiple annotators. In our case usually

7:28

the clinical expert or a product

7:30

manager. And

7:33

um and then for each example of the

7:36

evaluation data set, this annotator will

7:39

provide uh feedback uh using the uh

7:42

evalation criteria that were uh

7:44

previously defined.

7:47

Uh so once we collect the examples, the

7:50

final criteria and perform human

7:52

annotation, we have our final uh

7:55

evaluation data set.

7:59

So the evaluation data set is built. So

8:02

what comes next? Uh we need to build the

8:05

evaluators. So we can build either human

8:08

codes called code cold or ludge evolves.

8:10

And each one of these grading uh

8:12

approaches is suited for different tasks

8:15

with different uh with um with different

8:19

failure modes.

8:21

So we usually use human evaluations to

8:23

evaluate uh things that require complex

8:26

reasoning and uh that require complex

8:29

reasoning and uh tone. So u this method

8:33

although being time consuming and uh

8:36

expensive and can suffer from

8:38

interotator disagreement is essential to

8:41

evaluate things that require expert

8:43

judgment and or product taste.

8:47

So before uh major uh updates or

8:50

releases, we perform pair wise pair-wise

8:52

comparison in Gondola, our uh internal

8:55

annotation uh tool where we ask uh human

8:59

uh evaluators, experts to evaluate the

9:01

model's output based on um based on

9:05

their um on their scores. We make

9:08

deployment decisions. So if a model is

9:10

ready or not to uh go to production.

9:15

Um then we use codebased evaluators to

9:17

evaluate things that have clear and

9:19

objective uh criteria. Their key

9:21

advantage is scalability. Uh created

9:24

once can be used to run thousands of

9:27

evaluators

9:29

quickly and uh consistently.

9:33

So this is an example of a code

9:35

evaluator that we use. This is a rather

9:37

simple one and that is used to make sure

9:40

that the output of uh the model remains

9:43

within a specific number of uh

9:46

characters.

9:48

So um then moving on to evaluators. So

9:52

they are a bit of a middle ground

9:54

between code based and human based uh

9:56

evaluators. Um so we so on one uh side

10:02

um they are able to evaluate things that

10:04

are more uh complex and subjective than

10:06

codebase evaluators and on the other

10:08

side they are able to uh process

10:11

thousands of evaluators

10:14

uh in a short amount of time.

10:18

So the key thing here with LLM uh as

10:20

judge evaluators is to create the LLM as

10:24

judge prompt. So this is an example of

10:25

the prompt that we use to evaluate Fenix

10:28

conversations. So if I was not standing

10:31

in front of it, you were able to see

10:32

that we define uh the task, we include

10:35

the transcript perform include also the

10:38

rubric item which which is which are the

10:41

evaluation criteria that I talked about

10:44

earlier and then the instructions for

10:45

the um evaluation. So in order to

10:49

guarantee that this um this evaluation

10:51

is aligned with human judgment, we

10:53

divide the evaluation data set into

10:56

three sets. The um training set,

10:59

development sets and the test set. The

11:01

training set is used for few short

11:02

examples. The development set is used to

11:05

iterate on the prompt and measure human

11:08

alignment. And then the test set is is

11:11

kept untouched until the end. and uh it

11:14

is used to have a measure of uh

11:18

performance.

11:21

So this is the process that we follow.

11:23

We start simple by defining the prompt

11:25

with clear structure and clear criteria.

11:28

Then we evaluate the examples of the

11:31

development set using the created

11:33

evaluators and then we measure things

11:35

such as true positive rate or true

11:38

negative rate and then we analyze

11:40

mistakes. So the examples where the

11:43

human and the model disagree. Then we

11:46

refine the evaluation prompt in order to

11:48

reduce the number of mistakes. And once

11:51

we and we repeat the entire process a

11:54

few number of times until we are uh

11:56

satisfied with the level of of

11:58

agreement.

12:00

Once the level of once the desired level

12:04

of agreement is uh reached uh we

12:07

evaluate performance on the test set.

12:15

So once the evaluation uh is created um

12:19

once the evalation suit is created, it

12:21

can be used to measure and compare the

12:24

performance of uh different versions

12:26

based on the uh created uh criteria and

12:31

they give us uh confidence about uh what

12:35

has improved or not on uh the new

12:38

version.

12:41

So however although we can spend a lot

12:44

of time in building uh evaluators

12:46

something that we cannot escape escape

12:49

from is veing.

12:51

So [clears throat]

12:52

um before releasing the model to

12:55

production we always or most of the

12:57

times perform a v check round which is

13:00

basically a manual inspection of uh

13:03

outputs. Um the goal is to ensure that

13:05

no unexpected issues not yet covered by

13:08

the evaluators uh surface if false

13:11

checks we release the hope the new and

13:13

hopefully improved version uh to

13:16

production.

13:19

However, although uh evaluations allow

13:21

us to track performance on different

13:23

criteria, they sometimes fail to uh get

13:26

the full picture of uh quality. So a new

13:30

version can sometimes improve the

13:32

evaluation metrics but uh fail the V

13:35

check the V check. In that case we hold

13:37

the release and perform another

13:38

improvement cycle.

13:43

So uh to perform V check uh we can use

13:45

annotation tools such as Gondola that I

13:47

described earlier or Argilla in this

13:50

which is the one uh shown uh here. So

13:52

using these tools the reviewers can have

13:54

the full uh context uh the full context

13:57

and provide feedback in a structured

14:00

way.

14:02

So this is the entire process used for

14:05

development once again. So moving on to

14:08

online evaluations. So once released to

14:11

production the model continues under uh

14:14

evaluation. Um so continuous evaluation

14:17

ensures that the model performance holds

14:20

up in real world conditions that

14:22

regressions are caught earlier and that

14:24

user experience keeps improving with

14:26

every uh iteration. So we keep a tight

14:29

feedback loop between production in

14:31

development by enforcing guard rails

14:34

conducting AB tests performing manual

14:37

audit on production traces and running

14:39

evaluators on production traces as well.

14:42

the the insights collected through this

14:44

process are then fed back to the um to

14:48

the evaluation data set the criteria and

14:51

uh used to make sure that uh they

14:55

continue to be reliable and aligned uh

14:58

with uh real world conditions.

15:03

So regarding guard wells, some uh

15:05

evaluators can uh be used as uh guard

15:08

wells um and they act as real-time

15:10

safety checks that prevent unwanted

15:12

content from reaching the end uh user.

15:16

So typically they can be implemented as

15:18

codebased evolves such as the

15:21

uh shown here uh for latency

15:22

considerations. However, for more

15:24

critical validations like for example

15:26

detecting uh medical uh advice, we can

15:30

also rely on LLM as judge. Uh so when

15:33

the guardrails fail uh you you can

15:35

either fall back to a static message or

15:38

uh retry the generation a few times.

15:42

Nevertheless, the ultimate test of the

15:44

new release is conducted in production

15:47

through an u AB test. So this validates

15:50

if the new version drives the user

15:53

behaviors and outcomes that we aim for.

15:56

So in practice uh performing AB tests

15:58

with large language models is not very

16:00

different from performing AB tests with

16:02

common uh products. We need to define

16:05

success metrics which can be uh user

16:07

feedback metrics or usage metrics or

16:10

acceptance metrics and then we measure

16:12

the lift between the two uh model

16:15

versions. However, performing AB tests

16:18

with large language models suffers

16:19

suffers from the same problems than

16:21

usual AB tests. So, first you need to

16:24

convince stakeholders to hold on on

16:27

releasing a new version and hopefully

16:29

better to the large population.

16:32

Sometimes your your uh volume of data is

16:35

not enough to uh make decisions, right?

16:38

No one wants to wait two months to have

16:40

the results of an AB test. And also uh

16:43

you need to make sure that the test is

16:45

statistically sound so you don't uh take

16:48

false conclusions. Uh nevertheless even

16:50

if everything I just uh spoke checks out

16:53

you still need to or most of the times

16:56

what happens is that the new version is

16:58

not uh different from the previous

17:00

version.

17:03

So um we set up uh guardrails, conduct

17:07

tests and continue to monitor um in

17:10

production. How? Through manual

17:12

inspection. So as we know manual

17:14

inspection although a bit tiredome is

17:17

one of the is one of the highest uh

17:20

return on investment tasks in uh machine

17:23

learning. So by regularly reviewing

17:25

production traces, we are able to detect

17:27

uh failure patterns early, understand

17:30

their root causes, mitigate the issues

17:32

and create evaluations that prevent them

17:34

from uh resurfacing.

17:38

However, to make this effective, we need

17:41

you guessed it um extensive

17:44

observability. So for each request or a

17:47

sample you need to or we usually log

17:49

everything from inputs metadata

17:53

uh from inputs metadata outputs uh uh

17:58

documents retrieved through rag

18:00

different tool invocations user feedback

18:02

and evaluations when uh they exist. So

18:06

this visibility allows us to have a full

18:09

picture of what happens in production,

18:11

debug faster and solve issues more

18:14

efficiently.

18:16

Finally, so uh once observability is in

18:20

place, the same evaluators that were uh

18:22

created um and that are used to evaluate

18:25

offline can also be used to evaluate uh

18:27

production uh traces. So depending on

18:30

the criticality of the issue, these

18:31

evaluators can be used to evaluate all

18:34

production traces or just a subsample.

18:37

So in the case of Phoenix uh which has

18:40

and supervised conversations with

18:42

patients, the same sets of evaluators

18:44

that uh runs in uh production that runs

18:48

in development also runs in uh

18:51

production. So if pass rates drop below

18:54

a specific threshold, the team is prompt

18:57

to investigate and uh take corrective uh

19:00

measure.

19:04

So this is uh once again the entire

19:07

process uh that uh we follow. So making

19:10

large language models safe, reliable and

19:12

useful especially in healthcare means

19:15

building trustworthy systems that

19:16

improve with every interaction. So

19:19

evaluations must be a continuous process

19:21

and not a one-time thing. We need to um

19:25

define success early create uh data sets

19:29

uh build suits of uh evaluators and

19:32

continue to run these checks in

19:34

production with guardwells AB tests and

19:37

observabilities

19:38

and [clears throat] observability sorry.

19:40

So as large language models grow more

19:42

capable uh the bar for safe reliability

19:44

and and helpfulness must increase as

19:47

well. So the features that endure are

19:50

not the ones that move fastest but the

19:52

ones that can improve uh with every uh

19:55

new interaction. Thank you.

20:01

>> [music]

More transcripts

Explore other videos transcribed with YouTLDR.

Get the TLDR of any YouTube video

Transcribe, summarize, and repurpose videos in 125+ languages — free, no signup required.

Try YouTLDR Free