Well, you can get the FuzzyText objects value by calling like this:

>> f = factory.fuzzy.FuzzyText(length=15)
>> f.fuzz()

But, in this text, the characters can be both uppercase or lower case. So if you want exclusive lower case characters, then you can override the FuzzyText like this:

from factory.fuzzy import FuzzyText

class CustomFuzzyText(FuzzyText):
    def fuzz(self, *args, **kwargs):
       return super(CustomFuzzyText, self).fuzz(*args, **kwargs).lower()

and use it in the factory like this:

underscore_15 = CustomFuzzyText(prefix="aa_", length=12)  # or CustomFuzzyText(length=15)
Answer from ruddra on Stack Overflow
🌐
Faker
faker.readthedocs.io › en › master › providers › faker.providers.python.html
faker.providers.python — Faker 40.13.0 documentation
pystr_format(string_format: str = '?#-###{{random_int}}{{random_letter}}', letters: str = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ') → str¶ ... >>> Faker.seed(0) >>> for _ in range(5): ... fake.pystr_format() ...
🌐
Faker
faker.readthedocs.io › en › master › providers › baseprovider.html
faker.providers. - BaseProvider - Faker's documentation!
Generate a string with each question mark (‘?’) in text replaced with a random character from letters. By default, letters contains all ASCII letters, uppercase and lowercase. ... >>> Faker.seed(0) >>> for _ in range(5): ... fake.lexify(text='Random Identifier: ??????????') ...
🌐
Medium
medium.com › @randomstr › generating-random-strings-in-python-and-its-frameworks-31d2a5cd3f40
Generating Random Strings in Python and Its Frameworks | by Random STR | Medium
December 21, 2023 - Discuss Flask’s use of secrets module for secure random string generation in session management. Suggest using the native secrets module for Flask applications. ... Briefly discuss some popular third-party libraries like Faker for generating random strings.
🌐
Blue Book
lyz-code.github.io › blue-book › coding › python › faker
Faker - The Blue Book
from random import SystemRandom @pytest.fixture(scope="session", autouse=True) def faker_seed() -> int: """Create a random seed for the Faker library.""" return SystemRandom().randint(0, 999999)
🌐
FakerPHP
fakerphp.org › formatters › numbers-and-strings
Numbers and Strings - FakerPHP / Faker
echo $faker->bothify(); // '46 hd', '19 ls', '75 pw' echo $faker->bothify('?????-#####'); // 'lsadj-10298', 'poiem-98342', 'lcnsz-42938' Generate a string where * characters are replaced with a random character from the ASCII table.
🌐
GitHub
github.com › joke2k › faker
GitHub - joke2k/faker: Faker is a Python package that generates fake data for you. · GitHub
By default all generators share the same instance of random.Random, which can be accessed with from faker.generator import random.
Starred by 19.2K users
Forked by 2.1K users
Languages   Python
🌐
HexDocs
hexdocs.pm › faker › Faker.String.html
Faker.String — Faker v0.18.0 - Hex
Returns a random string taken from the Big List of Naughty Strings. iex> Faker.String.naughty() "̦H̬̤̗̤͝e͜ ̜̥̝̻͍̟́w̕h̖̯͓o̝͙̖͎̱̮ ҉̺̙̞̟͈W̷̼̭a̺̪͍į͈͕̭͙̯̜t̶̼̮s̘͙͖̕ ̠̫̠B̻͍͙͉̳ͅe̵h̵̬͇̫͙i̹͓̳̳̮͎̫̕n͟d̴̪̜̖ ̰͉̩͇͙̲͞ͅT͖...
🌐
CodingNomads
codingnomads.com › how-to-use-python-faker-random-data-generator
How to Use Python Faker: Random Data Generator
Using the Python faker.Faker class, you can generate all sorts of dummy data, like emails, usernames, and even dates in the past, using Faker's random fake data generator. The best part? At first glance, the generated data actually looks real.
Find elsewhere
🌐
GitHub
gist.github.com › rg3915 › 744aacde209046901748
Generate random values with Python gen_random faker gen_date fake gen date fake · GitHub
Generate random values with Python gen_random faker gen_date fake gen date fake - gen_random_values.py
🌐
Readthedocs
maleficefakertest.readthedocs.io › en › latest › providers › faker.providers.python.html
faker.providers.python — Faker 4.5.0 documentation
Generates a random string of upper and lowercase letters. :type min_chars: int :type max_chars: int :return: String. Random of random length between min and max characters. >>> Faker.seed(0) >>> for _ in range(5): ... fake.pystr() ...
🌐
Faker
faker.readthedocs.io › en › latest › providers › faker.providers.python.html
faker.providers.python — Faker 40.11.1 documentation
pystr_format(string_format: str = '?#-###{{random_int}}{{random_letter}}', letters: str = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ') → str¶ ... >>> Faker.seed(0) >>> for _ in range(5): ... fake.pystr_format() ...
🌐
Faker
faker.readthedocs.io › en › master › providers › faker.providers.misc.html
faker.providers.misc — Faker 40.11.1 documentation
Generate a random MD5 hash. If raw_output is False (default), a hexadecimal string representation of the MD5 hash will be returned. If True, a bytes object representation will be returned instead. ... >>> Faker.seed(0) >>> for _ in range(5): ... fake.md5(raw_output=False) ...
🌐
GitHub
github.com › joke2k › faker › blob › master › faker › providers › __init__.py
faker/faker/providers/__init__.py at master · joke2k/faker
- At symbols ('@') are replaced with a random non-zero digit or an empty string. · Under the hood, this method uses :meth:`random_digit() <faker.providers.BaseProvider.random_digit>`, :meth:`random_digit_not_null() ...
Author   joke2k
🌐
Towards Data Science
towardsdatascience.com › home › latest › fake (almost) everything with faker
Fake (almost) everything with Faker | Towards Data Science
January 19, 2025 - This is the output of a simple Python script that I wrote to generate fake customer data, or fake people. Looking at this, it’s amazing how realistic it looks. And the code I used to get this output is the following: ... print("My name is %s %s %s , I'm a gender neutral person. You can call me at %s, or email me at %s, or visit my home at %s" % (faker.prefix_nonbinary(), faker.name_nonbinary(), faker.suffix_nonbinary(), faker.phone_number(), faker.ascii_free_email(), faker.address())
🌐
PyPI
pypi.org › project › Faker
Faker · PyPI
By default all generators share the same instance of random.Random, which can be accessed with from faker.generator import random.
      » pip install Faker
    
Published   Apr 06, 2026
Version   40.13.0
🌐
Linux Hint
linuxhint.com › python-faker-generate-dummy-data
How to Use Python Faker to Generate Dummy Data – Linux Hint
Create a Python file with the following script that will generate three types of random numbers. The random_int() function will generate a random integer number. The random_number(digit=5) function will generate a random number of 5 digits. The random_int(50, 150) function will generate a random ...
🌐
Sling Academy
slingacademy.com › article › python-faker-how-to-set-min-max-length-for-random-text
Python + Faker: How to Set Min/Max Length for Random Text - Sling Academy
If you haven’t installed Faker yet, you can do it using pip: ... Once installed, let’s jump straight into how to manage text length in your random data generation. The simplest way to generate random text with Faker is through its text() method. By default, this method generates a string ...
🌐
Sling Academy
slingacademy.com › article › python-using-faker-to-generate-random-text
Python: Using Faker to Generate Random Text - Sling Academy
Python’s Faker library offers a robust solution to generate fake but realistic data, including random text for various purposes like testing and data masking.