Skip to content

Python Client built against the Wolfram|Alpha v2.0 API. Forked from Jarco's Bitbucket.

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE
Unknown
COPYING
Notifications You must be signed in to change notification settings

bmikolaj/wolframalpha

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

WolframAlpha Client

v1.3

Python Client built against the Wolfram|Alpha v2.0 API.

Original project is hosted on bitbucket.

Installation

  • Clone git archive via the following command;

    git clone https://github.com/bmikolaj/wolframalpha.git wolframalpha

  • Change directories via cd wolframalpha

  • Run the following command to install;

    sudo python setup.sh install

Usage

Basic usage is pretty simple. Create the client with your App ID (request from Wolfram Alpha);

import wolframalpha
client = wolframalpha.Client(app_id)

Then, you can send queries, which return Result objects;

res = client.query('temperature in Washington, DC on October 3, 2012')

If you need to need to specify an assumption, you can do the following;

res = client.query('1s + 1s','*C.s-_*Unit-')

This will assume s is a unit instead of a varaible

Result objects have pods attribute (a Pod is an answer from Wolfram Alpha);

for pod in res.pods:
    do_something_with(pod)

You may also query for simply the pods which have 'Result' titles;

print(next(res.results).text)

Changelog

  • v1.3 (21 October 2014)

    Added assumption option to query

  • v1.2 (08 June 2014)

    Release by jaraco forked

Authors

Brian Mikolajczyk, [email protected]

Jason R. Coombs, [email protected]

Legal

Copyright (c) 2014, Brian Mikolajczyk, [email protected]

Licence

Please see file LICENCE.

Copying

Please see file COPYING.

About

Python Client built against the Wolfram|Alpha v2.0 API. Forked from Jarco's Bitbucket.

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENSE
Unknown
COPYING

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages