File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change 11using Newtonsoft . Json ;
2+ using System . Collections . Generic ;
23using System . Linq ;
34
45namespace OpenAI_API . Embedding
@@ -12,7 +13,7 @@ public class EmbeddingResult : ApiResultBase
1213 /// List of results of the embedding
1314 /// </summary>
1415 [ JsonProperty ( "data" ) ]
15- public Data [ ] Data { get ; set ; }
16+ public List < Data > Data { get ; set ; }
1617
1718 /// <summary>
1819 /// Usage statistics of how many tokens have been used for this request
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ public void GetBasicEmbedding()
2424 var results = api . Embeddings . CreateEmbeddingAsync ( new EmbeddingRequest ( Model . AdaTextEmbedding , "A test text for embedding" ) ) . Result ;
2525 Assert . IsNotNull ( results ) ;
2626 Assert . NotNull ( results . Object ) ;
27- Assert . NotZero ( results . Data . Length ) ;
27+ Assert . NotZero ( results . Data . Count ) ;
2828 Assert . That ( results . Data . First ( ) . Embedding . Length == 1536 ) ;
2929 }
3030
You can’t perform that action at this time.
0 commit comments