@@ -62,17 +62,17 @@ function closeCapture(~)
62
62
methods (Test )
63
63
function testAnalyzeScientificPapersUsingFunctionCalls(testCase )
64
64
testCase .startCapture(" AnalyzeScientificPapersUsingFunctionCalls" );
65
- AnalyzeScientificPapersUsingFunctionCalls ;
65
+ evalc( " AnalyzeScientificPapersUsingFunctionCalls" ) ;
66
66
end
67
67
68
68
function testAnalyzeSentimentinTextUsingChatGPTwithStructuredOutput(testCase )
69
69
testCase .startCapture(" AnalyzeSentimentinTextUsingChatGPTwithStructuredOutput" );
70
- AnalyzeSentimentinTextUsingChatGPTwithStructuredOutput ;
70
+ evalc( " AnalyzeSentimentinTextUsingChatGPTwithStructuredOutput" ) ;
71
71
end
72
72
73
73
function testAnalyzeTextDataUsingParallelFunctionCallwithChatGPT(testCase )
74
74
testCase .startCapture(" AnalyzeTextDataUsingParallelFunctionCallwithChatGPT" );
75
- AnalyzeTextDataUsingParallelFunctionCallwithChatGPT ;
75
+ evalc( " AnalyzeTextDataUsingParallelFunctionCallwithChatGPT" ) ;
76
76
end
77
77
78
78
function testCreateSimpleChatBot(testCase ,ChatBotExample )
@@ -111,55 +111,55 @@ function testCreateSimpleChatBot(testCase,ChatBotExample)
111
111
numWordsResponse = []; % #ok<NASGU>
112
112
113
113
% Run the example
114
- eval (ChatBotExample );
114
+ evalc (ChatBotExample );
115
115
116
116
testCase .verifyEqual(count ,find(prompts ==" end" ,1 ));
117
117
testCase .verifySize(messages .Messages ,[1 2 *(count - 1 )]);
118
118
end
119
119
120
120
function testDescribeImagesUsingChatGPT(testCase )
121
121
testCase .startCapture(" DescribeImagesUsingChatGPT" );
122
- DescribeImagesUsingChatGPT ;
122
+ evalc( " DescribeImagesUsingChatGPT" ) ;
123
123
end
124
124
125
125
function testInformationRetrievalUsingOpenAIDocumentEmbedding(testCase )
126
126
testCase .startCapture(" InformationRetrievalUsingOpenAIDocumentEmbedding" );
127
- InformationRetrievalUsingOpenAIDocumentEmbedding ;
127
+ evalc( " InformationRetrievalUsingOpenAIDocumentEmbedding" ) ;
128
128
end
129
129
130
130
function testProcessGeneratedTextinRealTimebyUsingChatGPTinStreamingMode(testCase )
131
131
testCase .startCapture(" ProcessGeneratedTextinRealTimebyUsingChatGPTinStreamingMode" );
132
- ProcessGeneratedTextinRealTimebyUsingChatGPTinStreamingMode ;
132
+ evalc( " ProcessGeneratedTextinRealTimebyUsingChatGPTinStreamingMode" ) ;
133
133
end
134
134
135
135
function testProcessGeneratedTextInRealTimeByUsingOllamaInStreamingMode(testCase )
136
136
testCase .startCapture(" ProcessGeneratedTextInRealTimeByUsingOllamaInStreamingMode" );
137
- ProcessGeneratedTextInRealTimeByUsingOllamaInStreamingMode ;
137
+ evalc( " ProcessGeneratedTextInRealTimeByUsingOllamaInStreamingMode" ) ;
138
138
end
139
139
140
140
function testRetrievalAugmentedGenerationUsingChatGPTandMATLAB(testCase )
141
141
testCase .startCapture(" RetrievalAugmentedGenerationUsingChatGPTandMATLAB" );
142
- RetrievalAugmentedGenerationUsingChatGPTandMATLAB ;
142
+ evalc( " RetrievalAugmentedGenerationUsingChatGPTandMATLAB" ) ;
143
143
end
144
144
145
145
function testRetrievalAugmentedGenerationUsingOllamaAndMATLAB(testCase )
146
146
testCase .startCapture(" RetrievalAugmentedGenerationUsingOllamaAndMATLAB" );
147
- RetrievalAugmentedGenerationUsingOllamaAndMATLAB ;
147
+ evalc( " RetrievalAugmentedGenerationUsingOllamaAndMATLAB" ) ;
148
148
end
149
149
150
150
function testSummarizeLargeDocumentsUsingChatGPTandMATLAB(testCase )
151
151
testCase .startCapture(" SummarizeLargeDocumentsUsingChatGPTandMATLAB" );
152
- SummarizeLargeDocumentsUsingChatGPTandMATLAB ;
152
+ evalc( " SummarizeLargeDocumentsUsingChatGPTandMATLAB" ) ;
153
153
end
154
154
155
155
function testUsingDALLEToEditImages(testCase )
156
156
testCase .startCapture(" UsingDALLEToEditImages" );
157
- UsingDALLEToEditImages ;
157
+ evalc( " UsingDALLEToEditImages" ) ;
158
158
end
159
159
160
160
function testUsingDALLEToGenerateImages(testCase )
161
161
testCase .startCapture(" UsingDALLEToGenerateImages" );
162
- UsingDALLEToGenerateImages ;
162
+ evalc( " UsingDALLEToGenerateImages" ) ;
163
163
end
164
164
end
165
165
end
0 commit comments