Conserte esse codego para min @Override public GeckoResult<PromptResponse>…
Jump to turn (9)
- 1Conserte esse codego para min @Override public GeckoResult onFilePrompt(GeckoSes
- 2Apareceu esse erro error: incompatible types: GeckoResult cannot be converted to
- 3Apareceu esse erro error: incompatible types: GeckoResult cannot be converted to
- 4Continua com erro error: incompatible types: GeckoResult cannot be converted to
- 5Conserte esse codego geckoSes.setPromptDelegate(new GeckoSession.PromptDelegate(
- 6Tem erro error: incompatible types: GeckoResult cannot be converted to PromptRes
- 7Ta dando esse erro error: cannot find symbol result.thenAccept(res -> geckoResul
- 8Outro erro error: incompatible types: GeckoResult cannot be converted to PromptR
- 9Essa é a versão geckoview nightly 123.0.20231228170344 Apareceu esse erro : vari
- User
Conserte esse codego para min @Override public GeckoResult onFilePrompt(GeckoSession session, FilePrompt prompt) { // Your existing code to start the file chooser intent Intent intent = new Intent(Intent.ACTION_GET_CONTENT); intent.setType("/"); intent.addCategory(Intent.CATEGORY_OPENABLE); currentFilePrompt = prompt; filePromptFuture = new CompletableFuture<>(); startActivityForResult(intent, FILE_UPLOAD_REQUEST_CODE); // Create a new GeckoResult GeckoResult geckoResult = new GeckoResult<>(); // When the CompletableFuture is completed, complete the GeckoResult filePromptFuture.whenComplete((result, throwable) -> { if (throwable != null) { // Complete the GeckoResult exceptionally if there is a throwable geckoResult.completeExceptionally(throwable); } else { // Otherwise, complete it with the result PromptResponse result = geckoResult.future.get();
geckoResult.complete(result); } }); return geckoResult; } - Assistant
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.