Loading...
    • Guida per sviluppatori
    • Riferimento API
    • MCP
    • Risorse
    • Note sulla versione
    Search...
    ⌘K
    Risorse
    PanoramicaGlossarioPrompt di sistema
    Libreria di promptCosmic KeystrokesCorporate clairvoyantWebsite wizardExcel formula expertGoogle apps scripterPython bug busterTime travel consultantStorytelling sidekickCita le tue fontiSQL sorcererDream interpreterPun-ditCulinary creatorPortmanteau poetHal the humorous helperLaTeX legendMood colorizerGit gudSimile savantEthical dilemma navigatorMeeting scribeIdiom illuminatorCode consultantFunction fabricatorNeologism creatorCSV converterEmoji encoderProse polisherPerspectives pondererTrivia generatorMindfulness mentorSecond-grade simplifierVR fitness innovatorPII purifierMemo maestroCareer coachGrading guruTongue twisterInterview question crafterGrammar genieRiddle me thisCode clarifierAlien anthropologistData organizerBrand builderEfficiency estimatorReview classifierDirection decoderMotivational museEmail extractorMaster moderatorLesson plannerSocratic sageAlliteration alchemistFuturistic fashion advisorPolyglot superpowersProduct naming proPhilosophical musingsSpreadsheet sorcererSci-fi scenario simulatorAdaptive editorBabel's broadcastsTweet tone detectorAirport code analyst
    Console
    Log in
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...
    Loading...

    Solutions

    • AI agents
    • Code modernization
    • Coding
    • Customer support
    • Education
    • Financial services
    • Government
    • Life sciences

    Partners

    • Amazon Bedrock
    • Google Cloud's Vertex AI

    Learn

    • Blog
    • Catalog
    • Courses
    • Use cases
    • Connectors
    • Customer stories
    • Engineering at Anthropic
    • Events
    • Powered by Claude
    • Service partners
    • Startups program

    Company

    • Anthropic
    • Careers
    • Economic Futures
    • Research
    • News
    • Responsible Scaling Policy
    • Security and compliance
    • Transparency

    Learn

    • Blog
    • Catalog
    • Courses
    • Use cases
    • Connectors
    • Customer stories
    • Engineering at Anthropic
    • Events
    • Powered by Claude
    • Service partners
    • Startups program

    Help and security

    • Availability
    • Status
    • Support
    • Discord

    Terms and policies

    • Privacy policy
    • Responsible disclosure policy
    • Terms of service: Commercial
    • Terms of service: Consumer
    • Usage policy
    Libreria di prompt

    Analista di codici aeroportuali

    Trova ed estrai i codici aeroportuali dal testo.

    Copia questo prompt nella nostra Console per provarlo tu stesso!

    Contenuto
    SystemIl tuo compito è analizzare il testo fornito e identificare eventuali codici aeroportuali menzionati al suo interno. Presenta questi codici aeroportuali come un elenco nell'ordine in cui appaiono nel testo. Se non vengono trovati codici aeroportuali, restituisci un elenco vuoto.
    UserIl mio prossimo viaggio prevede di volare da Seattle ad Amsterdam. Passerò alcuni giorni ad Amsterdam prima di dirigermi a Parigi per un volo di collegamento a Roma.

    Output di esempio

    Ecco l'elenco dei codici aeroportuali menzionati nel testo, nell'ordine in cui appaiono:

    1. SEA (Seattle)
    2. AMS (Amsterdam)
    3. CDG (Parigi)
    4. FCO (Roma)

    Richiesta API

    import anthropic
    
    client = anthropic.Anthropic(
        # defaults to os.environ.get("ANTHROPIC_API_KEY")
        api_key="my_api_key",
    )
    message = client.messages.create(
        model="claude-opus-4-6",
        max_tokens=1000,
        temperature=0,
        system="Your task is to analyze the provided text and identify any airport codes mentioned within it. Present these airport codes as a list in the order they appear in the text. If no airport codes are found, return an empty list.",
        messages=[
            {
                "role": "user",
                "content": [
                    {
                        "type": "text",
                        "text": "My next trip involves flying from Seattle to Amsterdam. I'll be spending a few days in Amsterdam before heading to Paris for a connecting flight to Rome."
                    }
                ]
            }
        ]
    )
    print(message.content)
    

    Was this page helpful?

    • Output di esempio
    • Richiesta API