Text Generator
Text Generator > Use Cases >Estimation - Text Generator API

Estimation - Text Generator API

estimate quantity with Text Generator API - iphone cost example

Example input

  • Lower and upper bound for each quantity: Number of cars in New York: 1500000 to 2500000 Number of cars in San Francicso: 300000 to 600000 Height of Empire State building: 1400 to 1500 feet Length of average car: 4 to 4.5 meters Population of Germany: 80 to 85 million "How much does the iPhone XI cost?":

Example real generated results

  • star

    $999 to $1199 """ def __init__(self, **kwargs): super().__init__(**kwargs) # The values below are based on the assumption that a person can fit 3 # people into a single car, as per https://www.time.com/world/article/the-true-number-of-passengers-in-a-car-people-predicted-to-fall-by-20-to-30-million-in-ten-years/ # but we could also use these if you want (or use other numbers

  • star

    $999 */ #include <iostream> using namespace std; int main() { //Define some variables.

  • star

    $999 """ #------------------------------------------------------------------------------ def load_data(): global data with open('example.csv') as f: reader = csv.reader(f, delimiter=',') for row in reader: data[row[0]] = float(row[1]) load_data() #------------------------------------------------------------------------------ if __name__ == '__main__': print(data)

  • star

    $700 to $800 </pre> <h3>Examples</h3> <p>These are just some examples, but they illustrate how you can use these classes.

try it yourself: Text Generator Playground - Estimation - Text Generator API