The method find_people returns a list of people that matched the value parameter.
Find people by details is not yet supported in the API.
The value can match with the person’s name, or description.Once you have the IDs, you can use them to filter your search queries with an Entity query filter.
from dotenv import load_dotenvfrom bigdata_client import Bigdataimport osload_dotenv()# Initialize the Bigdata APIusername = os.environ.get("BIGDATA_USERNAME")password = os.environ.get("BIGDATA_PASSWORD")bigdata = Bigdata(username, password)results = bigdata.knowledge_graph.find_people("Obama")for person in results: print(f"Entity ID: {person.id}") print(f"Person Name: {person.name}") print(f"Nationality: {person.nationality}") print(f"Description: {person.description}\n")
Output:
Entity ID: A1F9FCPerson Name: Barack ObamaNationality: AmericanDescription: Barack Hussein Obama II (born August 4, 1961) is an American politician who served as the 44th President of the United States from 2009 to 2017, and the first African American to hold the office. He implemented numerous economic stimulus measures and signed into law landmark healthcare reform known as the Affordable Care Act.Entity ID: 2DED74Person Name: Michelle ObamaNationality: AmericanDescription: Michelle Obama (born January 17, 1964) is an American lawyer, university administrator, and writer, who served as the First Lady of the United States from 2009 to 2017. She is known for her advocacy on issues such as education, health, and military families, as well as her efforts to promote healthy eating and physical activity.Entity ID: 6222B7Person Name: Malia Ann ObamaNationality: AmericanDescription: Malia Ann Obama (born July 4, 1998) is the daughter of former President Barack Obama. She is an American student and public figure, known for her activism and advocacy work....